Skip to content

illegal chars accepted in literal strings

Ghc accepts literal tab characters inside literal strings, even though these are not permitted by Haskell'98. Example:

Prelude> "^I" "\t" Prelude>

Other compilers correctly reject them:

nhc98> "^I" Error at line 1, column 2: Tab in literal string/char. Use \t instead.

Trac metadata
Trac field Value
Version 6.6
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Compiler
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system Multiple
Architecture Multiple
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information