diff --git a/config/JarMaker.py b/config/JarMaker.py index a1dbe56cc5a6..f44e3b374006 100644 --- a/config/JarMaker.py +++ b/config/JarMaker.py @@ -370,7 +370,6 @@ class JarMaker(object): pp.setMarker('%') pp.out = outf pp.do_include(inf) - pp.warnUnused(realsrc) outf.close() inf.close() return diff --git a/config/Preprocessor.py b/config/Preprocessor.py index 78c38004573c..72eef449645f 100644 --- a/config/Preprocessor.py +++ b/config/Preprocessor.py @@ -41,7 +41,6 @@ class Preprocessor: 'LINE': 0, 'DIRECTORY': os.path.abspath('.')}.iteritems(): self.context[k] = v - self.actionLevel = 0 self.disableLevel = 0 # ifStates can be # 0: hadTrue @@ -75,13 +74,6 @@ class Preprocessor: self.LE = '\n' self.varsubst = re.compile('@(?P\w+)@', re.U) - def warnUnused(self, file): - if self.actionLevel == 0: - sys.stderr.write('%s: WARNING: no preprocessor directives found\n' % file) - elif self.actionLevel == 1: - sys.stderr.write('%s: WARNING: no useful preprocessor directives found\n' % file) - pass - def setLineEndings(self, aLE): """ Set the line endings to be used for output. @@ -145,7 +137,6 @@ class Preprocessor: includes.extend(args) for f in includes: self.do_include(f, False) - self.warnUnused(f) pass def getCommandLineParser(self, unescapeDefines = False): @@ -195,8 +186,6 @@ class Preprocessor: """ Handle a single line of input (internal). """ - if self.actionLevel == 0 and self.comment.match(aLine): - self.actionLevel = 1 m = self.instruction.match(aLine) if m: args = None @@ -210,8 +199,6 @@ class Preprocessor: level, cmd = self.cmds[cmd] if (level >= self.disableLevel): cmd(args) - if cmd != 'literal': - self.actionLevel = 2 elif self.disableLevel == 0 and not self.comment.match(aLine): self.write(aLine) pass diff --git a/js/src/config/Preprocessor.py b/js/src/config/Preprocessor.py index 78c38004573c..72eef449645f 100644 --- a/js/src/config/Preprocessor.py +++ b/js/src/config/Preprocessor.py @@ -41,7 +41,6 @@ class Preprocessor: 'LINE': 0, 'DIRECTORY': os.path.abspath('.')}.iteritems(): self.context[k] = v - self.actionLevel = 0 self.disableLevel = 0 # ifStates can be # 0: hadTrue @@ -75,13 +74,6 @@ class Preprocessor: self.LE = '\n' self.varsubst = re.compile('@(?P\w+)@', re.U) - def warnUnused(self, file): - if self.actionLevel == 0: - sys.stderr.write('%s: WARNING: no preprocessor directives found\n' % file) - elif self.actionLevel == 1: - sys.stderr.write('%s: WARNING: no useful preprocessor directives found\n' % file) - pass - def setLineEndings(self, aLE): """ Set the line endings to be used for output. @@ -145,7 +137,6 @@ class Preprocessor: includes.extend(args) for f in includes: self.do_include(f, False) - self.warnUnused(f) pass def getCommandLineParser(self, unescapeDefines = False): @@ -195,8 +186,6 @@ class Preprocessor: """ Handle a single line of input (internal). """ - if self.actionLevel == 0 and self.comment.match(aLine): - self.actionLevel = 1 m = self.instruction.match(aLine) if m: args = None @@ -210,8 +199,6 @@ class Preprocessor: level, cmd = self.cmds[cmd] if (level >= self.disableLevel): cmd(args) - if cmd != 'literal': - self.actionLevel = 2 elif self.disableLevel == 0 and not self.comment.match(aLine): self.write(aLine) pass