Closed anikaks closed 2 years ago
So a file with no statements in it is legal, and if you parse a file containing a single newline, everything works fine, but if you parse a file containing no characters, ANTLR refuses to return a parser.
I'll hack around it by parsing "" as "\n"
Good catch @anikaks ! All fixed.
I get an error when I have nothing in a .malloy file, but it doesn't seem to mind if there's stuff there but just commented out. Not sure if there's a reason not to do this, but I think having an immediate error when you create a file is a bit off-putting (plus the error persists if you delete said file), and ideally we could just accept empty models. no model:
commented model: