summary |
shortlog |
log |
commit | commitdiff |
review |
tree
raw |
patch |
inline | side by side (from parent 1:
4f740c8)
Change-Id: I964cb44f8604187390009dcef7dd766b3804c3ca
Type: make
Signed-off-by: Ole Troan <ot@cisco.com>
t_ignore_LINE_COMMENT = '//.*'
def t_NUM(self, t):
t_ignore_LINE_COMMENT = '//.*'
def t_NUM(self, t):
- r'0[xX][0-9a-fA-F]+|\d+'
+ r'0[xX][0-9a-fA-F]+|-?\d+'
base = 16 if t.value.startswith('0x') else 10
t.value = int(t.value, base)
return t
base = 16 if t.value.startswith('0x') else 10
t.value = int(t.value, base)
return t