[Haskell-beginners] Unicode characters in function names: some don't work?

Silent Leaf silent.leaf0 at gmail.com
Wed Apr 13 19:33:48 UTC 2016


Hi!

say I wanna use "—" as new infix operator: it's the big dash used a bit
like parenthesis, especially at the end of sentences —like this.

in ghci directly:
Prelude> let (—) a b = a + b

No problem, is accepted and usable. Same in files.

Now I try using (»), a French (amongst others) punctuation sign, typically
replaces the quote-ends, « like this ».
Doesn't work:
<interactive>:2:6: lexical error at character '\187'

I thought Haskell was Unicode-friendly? Why some symbols but not others? :'(
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/beginners/attachments/20160413/328aa152/attachment.html>


More information about the Beginners mailing list