erde-lang / erde

A programming language that compiles to Lua.
https://erde-lang.github.io
MIT License
40 stars 4 forks source link

Greedy interpolation parsing #24

Closed bsuth closed 1 year ago

bsuth commented 1 year ago

If a string only contains a brace, it will currently be parsed as interpolation:

print("\{")

This is because the escape will be removed by the tokenizer, but then interpreted as an interpolation by the compiler

bsuth commented 1 year ago

https://github.com/erde-lang/erde/commit/e34965b7885aeb1f767769f4abefa8f948a6860e