Skip to content

Comments

Add clojure-discard-face for #_ reader macro#692

Merged
bbatsov merged 1 commit intomasterfrom
add-clojure-discard-face
Feb 20, 2026
Merged

Add clojure-discard-face for #_ reader macro#692
bbatsov merged 1 commit intomasterfrom
add-clojure-discard-face

Conversation

@bbatsov
Copy link
Member

@bbatsov bbatsov commented Feb 20, 2026

Adds a dedicated clojure-discard-face for #_ discarded forms, so users can style them differently from regular comments. Inherits from font-lock-comment-face by default, so no visual change unless customized.

Unlike PR #689, this correctly preserves font-lock-comment-face for (comment ...) forms when clojure-comment-regexp is configured to match those.

Fixes #688
Supersedes #689

Introduce a dedicated `clojure-discard-face` that is applied to forms
discarded via `#_`. This allows users to style discarded forms
differently from regular comments. The face inherits from
`font-lock-comment-face` by default, so the visual appearance is
unchanged unless customized.

When `clojure-comment-regexp` is set to also match `(comment ...)`
forms, those continue to use `font-lock-comment-face`.
@bbatsov bbatsov mentioned this pull request Feb 20, 2026
5 tasks
@bbatsov bbatsov merged commit 7d3df43 into master Feb 20, 2026
6 of 7 checks passed
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.

Request: a distinct face for #_ forms

1 participant