Skip to content

fix(syntax): avoid treating Haskell operators as comments#3707

Open
imwyvern wants to merge 1 commit intosharkdp:masterfrom
imwyvern:clawoss/fix/3694-haskell-operator-comment
Open

fix(syntax): avoid treating Haskell operators as comments#3707
imwyvern wants to merge 1 commit intosharkdp:masterfrom
imwyvern:clawoss/fix/3694-haskell-operator-comment

Conversation

@imwyvern
Copy link
Copy Markdown

The Haskell syntax treated any -- sequence as a line comment starter, so legal operators such as --> in fixity declarations were highlighted as comments.

This adds a syntax patch matching double-dash comments only when the dash sequence is not followed by another Haskell operator character, while preserving normal comments like -- text and --foo.

Fixes #3694.

Verification:

  • patch --dry-run --strip=0 -d assets < assets/patches/Haskell.sublime-syntax.patch
  • regex smoke check for -- comment, --foo, ---, -->, and --->
  • assets/create.sh could not be run in this environment because bat is not installed on PATH.

@imwyvern imwyvern force-pushed the clawoss/fix/3694-haskell-operator-comment branch from bfc739f to 8b39d1f Compare April 28, 2026 08:12
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.

[Haskell] Haskell highlighting: Operator misinterpreted as comment

1 participant