comparison python/ppci/ir.py @ 303:be7f60545368

Final fixups
author Windel Bouwman
date Fri, 06 Dec 2013 12:37:48 +0100
parents 6753763d3bec
children fa99f36fabb5
comparison
equal deleted inserted replaced
302:2ef2247f8dda 303:be7f60545368
288 288
289 289
290 def Div(a, b): 290 def Div(a, b):
291 return Binop(a, '/', b) 291 return Binop(a, '/', b)
292 292
293
293 class Eseq(Expression): 294 class Eseq(Expression):
294 """ Sequence of instructions where the last is an expression """ 295 """ Sequence of instructions where the last is an expression """
295 def __init__(self, stmt, e): 296 def __init__(self, stmt, e):
296 self.stmt = stmt 297 self.stmt = stmt
297 self.e = e 298 self.e = e
471 assert isinstance(i, Statement) 472 assert isinstance(i, Statement)
472 i.debugLoc = self.loc 473 i.debugLoc = self.loc
473 if not self.bb: 474 if not self.bb:
474 raise Exception('No basic block') 475 raise Exception('No basic block')
475 self.bb.addInstruction(i) 476 self.bb.addInstruction(i)
476
477