Closed falkoschindler closed 2 years ago
Ah, this is because strtod
is used to parse numbers. It accepts hexadecimal numbers, while owl's hand-written integer parser doesn't. This is definitely an oversight.
This should be fixed in 92c1b65.
Awesome, that was quick! It seems to be working nicely. Thanks a lot!
I was thinking about adding support for hexadecimal arguments in my grammar, when I noticed that OWL already parses things like "0xff". But why is every hex input parsed as a number and not an integer? In my application it messes with the type checking system, because some function might expect an integer and would refuse to accept "0xff".
For example, the grammar
with the input
yields:
Would it be possible to distinguish hex integers and hex floating point numbers without writing a new tokenize function?