[Haskell] non-ASCII characters in Haddock documentation

Ross Paterson ross at soi.city.ac.uk
Mon Feb 16 11:29:40 EST 2004

On Mon, Feb 16, 2004 at 10:20:30AM -0000, Simon Marlow wrote:
> Wolfgang Jeltsch <wolfgang at jeltsch.net> writes:
> > I meant non-ASCII characters in source code comments like this:
> >     {-|
> >         The execution time of this function is /n³/.
> >     -}
> > Currently, Haddock seems to copy the bytes making up the 
> > non-ASCII character 
> > verbatim to the HTML file.  But since the HTML file doesn't contain a 
> > character set specification, it is illformed and it depends 
> > on the browser how this situation is handled.
> It shouldn't be too hard to fix this, at least for Latin-1 (full
> Unicode would be somewhat harder).  I'll add it to the TODO list.

While Haskell's source charset is specified as Unicode, Haskell source
files don't specify the byte encoding they use, so any source file using
non-ASCII characters isn't portable.  Entrenching Latin-1 would make the
move to Unicode more difficult.

More information about the Haskell mailing list