[ scintilla-Bugs-1777016 ] C++/JavaScript lexer: regex literals not always recognized

View: New views
3 Messages — Rating Filter:   Alert me  

[ scintilla-Bugs-1777016 ] C++/JavaScript lexer: regex literals not always recognized

by SourceForge.net :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Bugs item #1777016, was opened at 2007-08-18 23:00
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=102439&aid=1777016&group_id=2439

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Eric Promislow (ericp)
Assigned to: Nobody/Anonymous (nobody)
Summary: C++/JavaScript  lexer: regex literals not always recognized

Initial Comment:
Given code like this in a JavaScript file:

var a = /foo/;
var b = [/bar/, /other/];

"foo" and "other" are colored as SCE_C_REGEX,
but "bar" is colored as SCE_C_IDENTIFIER

The attached patch that does two things:

1. Extends the set of characters that can precede
a regex-delimiting '/' from
"(=," to "([{=,:;!%^&*|?~+-"

2. If the triggering character is '-' or '+',
a check is made to determine if it's part of
a '++' or '--' operator, or not.

----------------------------------------------------------------------

You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=102439&aid=1777016&group_id=2439
_______________________________________________
Scintilla-interest mailing list
Scintilla-interest@...
http://mailman.lyra.org/mailman/listinfo/scintilla-interest

Re: [ scintilla-Bugs-1777016 ] C++/JavaScript lexer: regex literals not always recognized

by Neil Hodgson :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

> Submitted By: Eric Promislow (ericp)
> Summary: C++/JavaScript  lexer: regex literals not always recognized

   Commited to CVS.

   Neil
_______________________________________________
Scintilla-interest mailing list
Scintilla-interest@...
http://mailman.lyra.org/mailman/listinfo/scintilla-interest

Re: [ scintilla-Bugs-1777016 ] C++/JavaScript lexer: regex literals not always recognized

by Eric Promislow :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Great, thanks again.

- Eric

Neil Hodgson wrote:

>> Submitted By: Eric Promislow (ericp)
>> Summary: C++/JavaScript  lexer: regex literals not always recognized
>
>    Commited to CVS.
>
>    Neil
> _______________________________________________
> Scintilla-interest mailing list
> Scintilla-interest@...
> http://mailman.lyra.org/mailman/listinfo/scintilla-interest
_______________________________________________
Scintilla-interest mailing list
Scintilla-interest@...
http://mailman.lyra.org/mailman/listinfo/scintilla-interest