GNU bug report logs -
#25529
25.1.90; js-mode: Regexp literal with unbalanced brackets breaks font-lock
Previous Next
Reported by: Mikhail Gusarov <mikhail <at> hola.org>
Date: Wed, 25 Jan 2017 11:15:02 UTC
Severity: minor
Found in version 25.1.90
Done: Tom Tromey <tom <at> tromey.com>
Bug is archived. No further changes may be made.
Full log
Message #23 received at 25529 <at> debbugs.gnu.org (full text, mbox):
Dmitry> This is very good, thank you. Here's just one example I've come so far
Dmitry> that works with the old code, but not with yours:
Dmitry> let x = /[/]/;
Dmitry> And that's probably just because the new js-syntax-propertize-regexp
Dmitry> doesn't move point forward after matching
Yep, adding a goto-char at the end of the function fixed this.
Thanks for pointing that out; I'll add a test case for it.
Dmitry> We could try to combine the regexps together, though. Then we'd move
Dmitry> the syntax-ppss status check inside the rule for the opening
Dmitry> delimiter, and use a simple one for the closer.
I think I understand combining the regexps. But what does using a simple
regexp for the closer mean?
Also, what is the purpose of the first call to
js-syntax-propertize-regexp in js-syntax-propertize?
Tom
This bug report was last modified 8 years and 180 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.