aboutsummaryrefslogtreecommitdiffhomepage
path: root/lexers/LexCPP.cxx
diff options
context:
space:
mode:
authornyamatongwe <devnull@localhost>2012-07-10 16:58:14 +1000
committernyamatongwe <devnull@localhost>2012-07-10 16:58:14 +1000
commite844abd0e4c7160c45399a8ec2595efb82368eac (patch)
treec125316f6f086bfd4ba83df61ba3558fc58e317b /lexers/LexCPP.cxx
parentd6c13c887bed0c7fb84edd56d6268bb7696ccf0e (diff)
downloadscintilla-mirror-e844abd0e4c7160c45399a8ec2595efb82368eac.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 = ' ';