Open AtomCrafty opened 2 years ago
I would change the grammar to also allow a single start index, in which case the end index would be assumed to be the same.
Good idea, and seems uncontroversial.
In addition, the grammar currently only allows integer literals as range specifiers, whereas it should really allow arbitrary constant expressions.
Yes, it could allow these for consistency reasons, though I don't think there's a pressing need for non-literal expressions in this context.
Encoding fields currently need to specify both a start and end index, even if they only consist of one bit. I would change the grammar to also allow a single start index, in which case the end index would be assumed to be the same.
In addition, the grammar currently only allows integer literals as range specifiers, whereas it should really allow arbitrary constant expressions.