comparison python/ppci/c3/parser.py @ 336:d1ecc493384e

Added spiffy armtoken class for bit fiddeling. Added cool test that checks for build repeatability
author Windel Bouwman
date Wed, 19 Feb 2014 22:32:15 +0100
parents 6f4753202b9a
children 5477e499b039
comparison
equal deleted inserted replaced
335:582a1aaa3983 336:d1ecc493384e
58 if t.typ != 'END': 58 if t.typ != 'END':
59 self.token = self.tokens.__next__() 59 self.token = self.tokens.__next__()
60 return t 60 return t
61 61
62 def addDeclaration(self, decl): 62 def addDeclaration(self, decl):
63 self.currentPart.declarations.append(decl) 63 self.currentPart.add_declaration(decl)
64 64
65 def parseImport(self): 65 def parseImport(self):
66 self.Consume('import') 66 self.Consume('import')
67 name = self.Consume('ID').val 67 name = self.Consume('ID').val
68 self.mod.imports.append(name) 68 self.mod.imports.append(name)