(stream)
| 219 | |
| 220 | // variable token |
| 221 | function hookVar(stream) { |
| 222 | // variables |
| 223 | // @@prefix.varName @varName |
| 224 | // varName can be quoted with ` or ' or " |
| 225 | // ref: http://dev.mysql.com/doc/refman/5.5/en/user-variables.html |
| 226 | if (stream.eat("@")) { |
| 227 | stream.match(/^session\./); |
| 228 | stream.match(/^local\./); |
| 229 | stream.match(/^global\./); |
| 230 | } |
| 231 | |
| 232 | if (stream.eat("'")) { |
| 233 | stream.match(/^.*'/); |
| 234 | return "variable-2"; |
| 235 | } else if (stream.eat('"')) { |
| 236 | stream.match(/^.*"/); |
| 237 | return "variable-2"; |
| 238 | } else if (stream.eat("`")) { |
| 239 | stream.match(/^.*`/); |
| 240 | return "variable-2"; |
| 241 | } else if (stream.match(/^[0-9a-zA-Z$\.\_]+/)) { |
| 242 | return "variable-2"; |
| 243 | } |
| 244 | return null; |
| 245 | }; |
| 246 | |
| 247 | // short client keyword token |
| 248 | function hookClient(stream) { |
nothing calls this directly
no outgoing calls
no test coverage detected