Sql Mode: Fixed string highlighting
This commit is contained in:
parent
e26ce00afb
commit
add0f3f5a2
1 changed files with 2 additions and 30 deletions
|
|
@ -45,22 +45,12 @@ var SqlHighlightRules = function() {
|
|||
"start" : [ {
|
||||
token : "comment",
|
||||
regex : "--.*$"
|
||||
}, {
|
||||
token : "string", // multi line " string start
|
||||
merge : true,
|
||||
regex : '".*$',
|
||||
next : "qqstring"
|
||||
}, {
|
||||
token : "string", // " string
|
||||
regex : '"(?:[^\\\\]|\\\\.)*?"'
|
||||
}, {
|
||||
token : "string", // multi line ' string start
|
||||
merge : true,
|
||||
regex : "'.*$",
|
||||
next : "qstring"
|
||||
regex : '".*"'
|
||||
}, {
|
||||
token : "string", // ' string
|
||||
regex : "'(?:[^\\\\]|\\\\.)*?'"
|
||||
regex : "'.*'"
|
||||
}, {
|
||||
token : "constant.numeric", // float
|
||||
regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
|
||||
|
|
@ -89,24 +79,6 @@ var SqlHighlightRules = function() {
|
|||
}, {
|
||||
token : "text",
|
||||
regex : "\\s+"
|
||||
} ],
|
||||
"qqstring" : [ {
|
||||
token : "string", // multi line " string end
|
||||
regex : '(?:[^\\\\]|\\\\.)*?"',
|
||||
next : "start"
|
||||
}, {
|
||||
token : "string",
|
||||
merge : true,
|
||||
regex : '.+'
|
||||
} ],
|
||||
"qstring" : [ {
|
||||
token : "string", // multi line ' string end
|
||||
regex : "(?:[^\\\\]|\\\\.)*?'",
|
||||
next : "start"
|
||||
}, {
|
||||
token : "string",
|
||||
merge : true,
|
||||
regex : '.+'
|
||||
} ]
|
||||
};
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue