Skip to content

Improve font locking performance on strings with escaped characters #591

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 2 commits into from
May 2, 2021

Conversation

yuhan0
Copy link
Contributor

@yuhan0 yuhan0 commented May 2, 2021

Fixes #589.

I'm not entirely sure what the original code was trying to achieve, but it was behaving pathologically on strings with lots of escaped characters (probably due to re-search-backward), so I reimplemented it in a more straightforward manner.

All tests are passing so it doesn't seem to have broken anything :)


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!

Sorry, something went wrong.

yuhan0 added 2 commits May 2, 2021 16:11

Verified

This commit was signed with the committer’s verified signature.
awvwgk Sebastian Ehlert
@bbatsov bbatsov merged commit 078f591 into clojure-emacs:master May 2, 2021
@bbatsov
Copy link
Member

bbatsov commented May 2, 2021

Thanks!

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.

clojure-mode locks up when font-locking strings with many escaped characters
2 participants