#217 Haskell single-quotes mis-highlighted

open
Nigel McNie
5
2013-06-27
2012-09-22
Anonymous
No

Single quotes in Haskell may be used in character literals:

a = 'a'

They may also be used in names:

f' x = x + 5

In this second case, GeSHi mistakes the single quote as the start delimiter of a string and highlights the remainder of the code as a string. The `'` character should not trigger string highlighting unless it is immediately followed by a single character and another `'`.

I've attached images from the GeSHi demo showing the second broken case.

Discussion


  • Anonymous
    2012-09-22

     
    Attachments
  • Sick! Just acquired a brand-new Pearl and I can now read your weblog on my phones browser, it didnt do the job on my aged 1.
    <a href="http://pancasukma.net63.net/index.php?p=blogs/viewstory/2167" title="where can i get a cocktail dress Inexpensive Weddi">where can i get a cocktail dress Inexpensive Weddi</a>

     
  • Gábor Lipták
    Gábor Lipták
    2013-06-27

    Another example of the Haskell formatting issue at pastebin

    http://pastebin.com/JuyaNLRp