Closed indutny closed 6 years ago
For example:
p.node('name')
.match(BIG_LIST, anotherNode)
.match(FEW_ITEMS, p.error(...))
.otherwise(p.error(...))
There's no need to kill optimization due to FEW_ITEMS
, since they should be rarely called. Split the node in translator, and move FEW_ITEMS
matching to otherwise clause of BitCheck
.
Alternatively, the table
could be made to contain multi-bit values instead of a single "check" bit. This way a switch after lookup could lead to both results.
We support bitfield with value width up to 4 bits now. Seems to be working great!
...and probably rename it to
bitcheck
.