~technomancy/fennel#193: 
Column -1 referenced in error message

If you try to parse the code "(do\n", the parser fails because of the missing parenthesis. However, the error message references column -1, which isn't a real place in the file.

$ fennel repro.txt
repro.txt:2:-1 Parse error: expected closing delimiter ) 
...

I would have expected something like 2:0.

I'm not sure if this is a very important issue, but I did encounter it in fennel-ls. My workaround in fennel-ls is to use (math.max col 0) instead of col, which changes it to the nearest valid location.

Status
RESOLVED FIXED
Submitter
~xerool
Assigned to
No-one
Submitted
11 months ago
Updated
5 months ago
Labels
bug

~technomancy REPORTED FIXED 5 months ago

Fixed in f80b947.

Register here or Log in to comment, or comment via email.