Thanks for reporting this.
I’m going to keep 0. invalid in ObjoBasic. Objo supports method calls directly on literals, for example:
42.ToString()
Because of that, a dot after a number already has an important meaning as member access. I think requiring at least one digit after the decimal point keeps numeric literals clearer and avoids making this part of the grammar more ambiguous. So the intended spelling is:
0.0
rather than:
0.
That said, the error message you hit was poor. Expected property name after "." is technically what the parser saw, but it doesn’t explain the real problem. I’ve changed this for the next release so 0. now reports:
Invalid numeric literal '0.'. Double literals must include digits after the decimal point; use '0.0'.
This preserves valid literal member calls like 42.ToString() while giving a much better diagnostic for this case.