-
Notifications
You must be signed in to change notification settings - Fork 33
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
no match 4 in highlight (4 font-lock-variable-name-face) #59
Comments
"GNU Emacs 28.2 (build 2, x86_64-pc-linux-gnu, GTK+ Version 3.24.20, cairo version 1.16.0) of 2022-09-16" Should I mention I am using native compilation? Sorry for being an ELISP noob. |
Since you are using Emacs 28: May I ask you to try the version of cperl-mode.el which comes with Emacs? The Emacs maintainers have incorporated jrockway's code (but not from the mx-declare branch), and CPerl Mode's font-locking has been rewritten after that. There are chances that the behavior was fixed "by accident". I'm asking because I can not reproduce the issue, with neither version of cperl-mode.el. If the error persists with the vanilla CPerl mode in your environment: Is there a Perl source you can share where this happens? Or can you provide a recipe how to reproduce when starting with |
Oh, I see, I am actually using the Vanilla CPerl mode. So maybe I should file a bug over there. But I'll still try to reproduce it with the least possible packages installed. Earlier, I googled for this error message and I found a fix in a completely unrelated package: Perhaps it's a similar issue causing the problem? |
Thanks for clarifying! This is my fault. When I rewrote Perl font-locking (which is part of Emacs 28), I missed one place where I needed to change the match count. I have fixed this in Emacs git in Nov 2021, but failed to notice that the fix has not been applied to the Emacs 28 branch. The fix is rather trivial: line 5949 of cperl-mode.el reads
This needs to be changed to:
...so if you don't want to wait for Emacs 28.3, you could patch if yourself. Sorry for the inconveniences! |
Cool, thanks so much for the update! BTW: Been using CPerl for years already, so thanks for all the work you and others put into it! |
The fix is now pushed to the Emacs release branch. So, with either Emacs 28.3 or 29.0 the problem will be officially solved. Is it OK if we close the issue in this repository? |
Yes. |
It seems cperl-mode triggers this error whenever I hit C-s and swiper.el runs for the first time in a buffer. I am not sure this is actually caused by cperl or swiper.el but my backtrace looks like this:
So the error is at least triggered downstream from "cperl-font-lock-fontify-region-function" which is why I am posting it here.
The text was updated successfully, but these errors were encountered: