nextjournal / lezer-clojure

This is a Clojure grammar for the lezer parser system.
ISC License
24 stars 3 forks source link

Fix rules for chars #17

Closed MrEbbinghaus closed 2 years ago

MrEbbinghaus commented 2 years ago

This PR addresses several issues regarding char detection.

Issues:

![\n\r\s] is not correct and results in: https://github.com/nextjournal/clojure-mode/issues/9

Actually, Clojure accepts \n and white spaces when in a form… Which is crazy…

Clojure 1.10.3
user=> \
Syntax error reading source at (REPL:2:1).
EOF while reading character
user=> [\ \a]
[\space \a]
user=> [\
 \a]
[\newline \a]
user=>

resolves https://github.com/nextjournal/clojure-mode/issues/22, resolves https://github.com/nextjournal/clojure-mode/issues/9

mk commented 2 years ago

@MrEbbinghaus thanks a lot for this!