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

Incorrect highlighting of empty typeclass #66

Closed
PerceptuallyUniform opened this issue Oct 22, 2018 · 3 comments
Closed

Incorrect highlighting of empty typeclass #66

PerceptuallyUniform opened this issue Oct 22, 2018 · 3 comments

Comments

@PerceptuallyUniform
Copy link

A class without any associated functions, e.g. just class A a, is valid Haskell, but gets highlighted incorrectly, as does everything following it.

Correct highlighting of non-empty class:
correct

Incorrect highlighting of empty class:
incorrect

@iko-deleted
Copy link

I just encountered this issue, and it's pretty annoying, due to its ability to wipe out highlighting for an entire file.

The bug appears to affect everything up until the next where, after which it returns to normal.

highlight-bug

Notably, this only happens for class declarations and not instance declarations.

@JustusAdam
Copy link
Owner

Hmm ... I guess for the time being you can just add the where. For empty type class (instances) it is optional

@JustusAdam
Copy link
Owner

Note to self: This issue may be fixable, by amending endCaptures to not only trigger on where but also a non-empty, unindented line

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

No branches or pull requests

3 participants