gcv / julia-snail

An Emacs development environment for Julia
GNU General Public License v3.0
236 stars 23 forks source link

Buffer does not parse on legal julia source code #6

Closed jlapeyre closed 4 years ago

jlapeyre commented 4 years ago

I am unable to run julia-snail-run-top-level-form on any function (form) in a file if the following line is in the file as well

many_rolls(n) = (+(roll_pair()...) for _ in 1:n)

The error is "Buffer does not parse; check Julia syntax".

gcv commented 4 years ago

Disclaimer: the Snail parser is the result of wanting structural information about the code of a language which has no formal grammar specification. 🤷🏻‍♂️ Which makes robust parsing of an arbitrary expression all but impossible. The parser has to rely on tricks and approximations.

Anyway, I pushed a change which should help this syntax. It should now be in MELPA. Please let me know if it works.

gcv commented 4 years ago

Please reopen if this still does not work.