Reading source files in text mode so that we get CRLF conversion under Windows?
According to https://github.com/sol/interpolate/issues/9 the string passed to a quasi quoter contains CRLF line endings. I have observed the same things for Haddock comments (both in haddock
and doctest
when extracted through the GHC API).
I haven't looked at any GHC code, but wouldn't the right thing be to read source files in text mode so that we get newline conversion? If we don't want / can't do that for some reason, then wouldn't we still want to handle this somewhere deep down the stack so that not every client has to deal with it separately?
Trac metadata
Trac field | Value |
---|---|
Version | 8.2.2 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | Compiler |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | |
Architecture |