Bug #18301 2011-08-10 13:51

petschy

Syntax highlighting goes off after R""

Wherever I write

R""

in a cpp file, the syntax highlighting switches off for the rest of the file, every character is plain black. Other letters won't do the trick (not tried all of them, though), just captial R. Writing a space between the R and " solves the problem.

I bumped into this when I had some string valued macros concatenated with string literals, like

#define BAR "bar"

char* baz = BAR"foo";

Is this a bug or a feature? :)

Present in SVN-7281 and 7359.

Regards, Peter

Category
Application::Editor
Group
 
Status
Open
Close date
 
Assigned to
 
ollydbg 2012-02-04 00:57

I think you should report this issue to scintilla component mail-list/forum, because c::b use this component. but this kind of issue is hard to handle because it need to do a lot of macro expansion.

petschy 2012-03-02 10:07

This is a scintilla bug, all right. The R prefix means raw string literal in C++0x, and it is not parsed correctly. The above bug was partially fixed already: BAR"foo" won't trigger it, though R""foo"" or R"$foo$" would, which are legal raw string literals.

This bug should be closed now.