aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMax <post@wickenrode.com>2015-02-01 18:36:22 +0100
committerMax <post@wickenrode.com>2015-02-01 18:37:03 +0100
commitc25bb060a197deecc79dac86e24df8246a87db71 (patch)
tree41824938bfe4eed07903cddf8bd06f9a31505d06
parentf2fc88bd1875d0dd6642c064c3528d0b5aeab09a (diff)
downloadsequelpro-c25bb060a197deecc79dac86e24df8246a87db71.tar.gz
sequelpro-c25bb060a197deecc79dac86e24df8246a87db71.tar.bz2
sequelpro-c25bb060a197deecc79dac86e24df8246a87db71.zip
Update lexer to reflect that backticks can actually escape themselves (won't cause visible changes)
-rw-r--r--Source/SPEditorTokens.l2
-rw-r--r--Source/SPSQLTokenizer.l2
2 files changed, 2 insertions, 2 deletions
diff --git a/Source/SPEditorTokens.l b/Source/SPEditorTokens.l
index 8a7c317b..e2d3099a 100644
--- a/Source/SPEditorTokens.l
+++ b/Source/SPEditorTokens.l
@@ -80,7 +80,7 @@ keywords (X(OR|509|A)|S(MALLINT|SL|H(OW({s}(E(NGINE(S)?|RRORS)|M(ASTER|UTEX)|BIN
\"([^"\\]|\\(.|[\n\r]))*\"? { return SPT_DOUBLE_QUOTED_TEXT; } /* double quoted strings */
'([^'\\]|\\(.|[\n\r]))*'? { return SPT_SINGLE_QUOTED_TEXT; } /* single quoted strings */
-`[^`]*`? { return SPT_BACKTICK_QUOTED_TEXT; } /* backtick quoted string */
+`(``|[^`])*`? { return SPT_BACKTICK_QUOTED_TEXT; } /* backtick quoted string */
"/*" { BEGIN(comment); return SPT_COMMENT; } /* beginning of a c style comment */
<comment>[^*]* { return SPT_COMMENT; } /* anything except * in a c cmnt */
diff --git a/Source/SPSQLTokenizer.l b/Source/SPSQLTokenizer.l
index b9170edb..f33d373d 100644
--- a/Source/SPSQLTokenizer.l
+++ b/Source/SPSQLTokenizer.l
@@ -63,7 +63,7 @@ compend {s}"end"
\"([^"\\]|\\(.|[\n\r]))*\"? { ; }
'([^'\\]|\\(.|[\n\r]))*'? { ; }
-`[^`]*`? { ; }
+`(``|[^`])*`? { ; }
"/*" { BEGIN(comment); }
<comment>[^*]* { ; }