comparison python/target.py @ 275:6f2423df0675

Fixed serve arm-as
author Windel Bouwman
date Sat, 14 Sep 2013 17:29:10 +0200
parents e41e4109addd
children 046017431c6a
comparison
equal deleted inserted replaced
274:ea93e0a7a31e 275:6f2423df0675
18 self.imm = imm 18 self.imm = imm
19 19
20 @classmethod 20 @classmethod
21 def Create(cls, vop): 21 def Create(cls, vop):
22 if type(vop) is ANumber and vop.number < 256: 22 if type(vop) is ANumber and vop.number < 256:
23 return cls(vop.number)
24
25 class Imm7:
26 def __init__(self, imm):
27 assert imm < 128
28 self.imm = imm
29
30 @classmethod
31 def Create(cls, vop):
32 if type(vop) is ANumber and vop.number < 128:
23 return cls(vop.number) 33 return cls(vop.number)
24 34
25 class Imm3: 35 class Imm3:
26 def __init__(self, imm): 36 def __init__(self, imm):
27 assert imm < 8 37 assert imm < 8