aboutsummaryrefslogtreecommitdiffhomepage
path: root/lexers/LexCPP.cxx
diff options
context:
space:
mode:
authornyamatongwe <unknown>2012-07-10 16:58:14 +1000
committernyamatongwe <unknown>2012-07-10 16:58:14 +1000
commit2c4c6392d5052c77e66ff124d7fde50a1207350a (patch)
tree5b19a8e5af76157ac3b8b4864fa767a4af708942 /lexers/LexCPP.cxx
parentff826c9bb5f479a9671532132e6a55149918d94e (diff)
downloadscintilla-mirror-2c4c6392d5052c77e66ff124d7fde50a1207350a.tar.gz
Turn off '$' when lexer.cpp.allow.dollars changes to 0. Bug #3541461.
Diffstat (limited to 'lexers/LexCPP.cxx')
-rw-r--r--lexers/LexCPP.cxx7
1 files changed, 6 insertions, 1 deletions
diff --git a/lexers/LexCPP.cxx b/lexers/LexCPP.cxx
index b8cc706e7..d6efa7ee0 100644
--- a/lexers/LexCPP.cxx
+++ b/lexers/LexCPP.cxx
@@ -379,6 +379,12 @@ public:
int SCI_METHOD LexerCPP::PropertySet(const char *key, const char *val) {
if (osCPP.PropertySet(&options, key, val)) {
+ if (strcmp(key, "lexer.cpp.allow.dollars") == 0) {
+ setWord = CharacterSet(CharacterSet::setAlphaNum, "._", 0x80, true);
+ if (options.identifiersAllowDollars) {
+ setWord.Add('$');
+ }
+ }
return 0;
}
return -1;
@@ -453,7 +459,6 @@ void SCI_METHOD LexerCPP::Lex(unsigned int startPos, int length, int initStyle,
if (options.identifiersAllowDollars) {
setWordStart.Add('$');
- setWord.Add('$');
}
int chPrevNonWhite = ' ';