gren-lang / compiler

Compiler for the Gren programming language
https://gren-lang.org
Other
379 stars 23 forks source link

Allow CRLF at the start of multiline strings #255

Closed mbartlett21 closed 2 months ago

mbartlett21 commented 3 months ago

This should fix #254.

I also fixed another bug while I was at it. Gren was silently dropping the last newline if the string didn't end with a newline.

robinheghan commented 2 months ago

Code formatting check fails.

To apply correct code formatting, install ormolu and run ormolu --mode inplace $(git ls-files '*.hs')

mbartlett21 commented 2 months ago

@robinheghan I've added another test for if it doesn't end with a newline, which was previously wrong. I.e.

"""testing
testing"""

previously dropped the newline