expected
The following code:
parseExpWithMode defaultParseMode {extensions = EnableExtension TemplateHaskell: EnableExtension UnicodeSyntax: extensions defaultParseMode} "⟦x⟧"— Works and outputs some syntax tree.
actual
A parse error comes out:
ParseFailed ( SrcLoc "<unknown>.hs" 1 1 ) "Parse error: ⟦"
discussion
it works fine with ASCII
The following:
parseExpWithMode defaultParseMode {extensions = EnableExtension TemplateHaskell: EnableExtension UnicodeSyntax: extensions defaultParseMode} "[|x|]"— Works and outputs some syntax tree.
the test case is broken
There is a test case tests/examples/brackets.hs that is expected to fail!
For example, this is the contents of the file tests/examples/brackets.hs.prettyprinter.golden:
ParseFailed (SrcLoc "tests/examples/brackets.hs" 17 3) "Parse error: \10631"
I reckon so because of #364. However, this test case checks for two things:
- Unicode syntax for arrows.
- Unicode syntax for Template Haskell.
There should ideally be two different test cases for these two features. Is there something that stops us from parsing Unicode Template Haskell expressions?