Place main code into own function
This commit is contained in:
parent
75bb4a96cb
commit
4038d4b562
|
@ -499,7 +499,7 @@ class MatchCompiler:
|
|||
self._assertEquals(self.parseMatch(' Token::Match(tok,', 2), None) # multiline Token::Match is not supported yet
|
||||
self._assertEquals(self.parseMatch(' Token::Match(Token::findsimplematch(tok,")"), ";")', 2), ['Token::Match(Token::findsimplematch(tok,")"), ";")', 'Token::findsimplematch(tok,")")', ' ";"']) # inner function call
|
||||
|
||||
|
||||
def main():
|
||||
# Main program
|
||||
build_dir = 'build'
|
||||
|
||||
|
@ -526,3 +526,6 @@ mc = MatchCompiler(verify_mode=args.verify)
|
|||
for f in glob.glob('lib/*.cpp'):
|
||||
print (f + ' => ' + build_dir + '/' + f[4:])
|
||||
mc.convertFile(f, build_dir + '/'+f[4:])
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
|
|
Loading…
Reference in New Issue