Skip to content

Fix some issues with indentation for items with metadata #68

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

Merged
merged 1 commit into from
Apr 3, 2025

Conversation

rrudakov
Copy link
Contributor

  • Collection elements (except of lists) are properly indented.
  • Body of special forms when the entire form has metadata is properly indented.
  • Additionally fix syntax highlighting of special forms when the entire form has metadata.

Close #61

Before:
image

Here besides incorrect indentation, if is not highlighted properly:
image

After:
image

image

Before submitting a PR mark the checkboxes for the items you've done (if you
think a checkbox does not apply, then leave it unchecked):

  • The commits are consistent with our contribution guidelines.
  • You've added tests (if possible) to cover your change(s). Bugfix, indentation, and font-lock tests are extremely important!
  • You've run M-x checkdoc and fixed any warnings in the code you've written.
  • You've updated the changelog (if adding/changing user-visible functionality).
  • You've updated the readme (if adding/changing user-visible functionality).

Thanks!

@rrudakov rrudakov force-pushed the fix/indentation-with-metadata branch from 7695b66 to e369db9 Compare March 28, 2025 12:08
@bbatsov
Copy link
Member

bbatsov commented Apr 3, 2025

Overall the change seem good to me.

@rrudakov
Copy link
Contributor Author

rrudakov commented Apr 3, 2025

Thanks for the review @bbatsov. Writing docstrings is definitely not one of my strengths :) I'll fix everything shortly.

@rrudakov rrudakov force-pushed the fix/indentation-with-metadata branch from e369db9 to b2a2867 Compare April 3, 2025 15:16
@rrudakov rrudakov requested a review from bbatsov April 3, 2025 15:16
…tadata

- Collection elements (except of lists) are properly indented.
- Body of special forms when the entire form has metadata is properly indented.
- Additionally fix syntax highlighting of special forms when the entire form has metadata.
@rrudakov rrudakov force-pushed the fix/indentation-with-metadata branch from b2a2867 to cd5c078 Compare April 3, 2025 15:40
@bbatsov bbatsov merged commit 7497ae9 into clojure-emacs:main Apr 3, 2025
2 of 3 checks passed
@rrudakov rrudakov deleted the fix/indentation-with-metadata branch April 3, 2025 15:46
@bbatsov
Copy link
Member

bbatsov commented Apr 3, 2025

Thanks for another great PR! And sorry for the slow turnaround here!

@rrudakov
Copy link
Contributor Author

rrudakov commented Apr 3, 2025

And sorry for the slow turnaround here!

No problem at all :)

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.

Incorrect indentation / fontification after metadata forms
2 participants