Michael Brown
unread,Apr 20, 2013, 5:48:18 PM4/20/13Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to utah-compiler...@googlegroups.com
The grammar for P4 indicates bitwise-and as a <binop> with the two arguments and the continuation. Tests 29 and 30 break these constraints and add more than two expressions to bitwise-and and those family of bitwise operations. I took the strict approach of matching the <unop>, <binop>, and <triop> based on their number of expressions and the operator name. This was overkill but it was so I could strictly follow the grammar. I will admit though I should have noticed that bitwise-and could take more than only two arguments in the class's implementation of the compiler so far.
Note: I have already fixed this in my implementation under the allowed diff, but I think it might be nice to correct the grammar for future classes.