if(parse_debug):
print('number_1', list(p))
+ p[1] = p[1].replace("'b", "0b")
+ p[1] = p[1].replace("'x", "0x")
+ num = Leaf(token.NUMBER, "%s" % (p[1]))
+ p[0] = num
+
# { p[0] = p[1]; based_size = 0;}
()
'''number : DEC_NUMBER '''
if(parse_debug):
print('number_2', list(p))
+ p[1] = p[1].replace("'b", "0b")
+ p[1] = p[1].replace("'x", "0x")
num = Leaf(token.NUMBER, "%s" % (p[1]))
p[0] = num
'''number : DEC_NUMBER BASED_NUMBER '''
if(parse_debug):
print('number_3', list(p))
- num = Leaf(token.NUMBER, "%s:%s" % (p[1], p[2]))
+
+ p[2] = p[2].replace("'b", "0b")
+ p[2] = p[2].replace("'x", "0x")
+
+ num = Leaf(token.NUMBER, "%s" % (p[2]))
p[0] = num
if(parse_debug):
print('expression_46', list(p))
- p[0] = Node(syms.atom, [p[1], Leaf(token.STRING, ' ? '),
- p[4], Leaf(token.STRING, ' : '), p[6]])
+ try:
+ p[0] = Node(syms.atom, [p[1], Leaf(token.STRING, ' ? '),
+ p[4], Leaf(token.STRING, ' : '), p[6]])
+ except:
+ p[0] = "error in PETernary"
# { PETernary*tmp = new PETernary(p[1], p[4], p[6]);
if(parse_debug):
print('hierarchy_identifier_3', list(p))
+ p[0] = Node(syms.atom, [p[1], Leaf(
+ token.STRING, '['), p[3], Leaf(token.STRING, ']')])
+
# { pform_name_t * tmp = p[1];
# name_component_t&tail = tmp->back();
if(parse_debug):
print('module_item_40', list(p))
+ absyn.always_ff(p[3], p[1])
+
# { PProcess*tmp = pform_make_behavior(IVL_PR_ALWAYS_FF, p[3], p[1]);
# FILE_NAME(tmp, @2);
if(parse_debug):
print('statement_item_30', list(p))
+ p[0] = [p[1], p[2]]
+
# { PEventStatement*tmp = p[1];
# if (tmp == 0) {
if(parse_debug):
print('statement_item_35', list(p))
+ p[0] = absyn.assign3(p[1], p[2], p[3])
+
# { PAssignNB*tmp = new PAssignNB(p[1],p[3]);
# FILE_NAME(tmp, @1);