Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Treat ids with double primes correctly (fixes #11) #12

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

aztek
Copy link

@aztek aztek commented Nov 26, 2014

Do not highlight identifiers with double primes as character literals in Haskell. The bug seems to be in an extra condition that checks if we are at the beginning of a character literal. The test file for Haskell looks fine after this change.

Do not highlight identifiers with double primes as character literals in Haskell. The bug seems to be in an extra condition that checks if we are at the beginning of a character literal. The test file for Haskell looks fine after this change.
@tmont
Copy link
Owner

tmont commented Dec 1, 2014

Cool! Can you provide a little haskell snippet containing a double prime that we can put in the test file?

Extra code to test identifiers with single quotes in them. Only 'c' should be highlighted as a character literal, the rest are legal identifiers.
@aztek
Copy link
Author

aztek commented Dec 2, 2014

This one should be enough.

c :: Char
c = c'
  where c' = c''
        c'' = c'''
        c''' = c'c'
        c'c' = c'c''
        c'c'' = c''c''
        c''c'' = 'c'

(Apparently, GitHub's syntax highlighter doesn't handle quotes wery well either.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants