(quote)
| 91 | } |
| 92 | |
| 93 | function tokenString(quote) { |
| 94 | return function(stream, state) { |
| 95 | var escaped = false, ch; |
| 96 | while ((ch = stream.next()) != null) { |
| 97 | if (ch == quote && !escaped) { |
| 98 | if (quote == ")") stream.backUp(1); |
| 99 | break; |
| 100 | } |
| 101 | escaped = !escaped && ch == "\\"; |
| 102 | } |
| 103 | if (ch == quote || !escaped && quote != ")") state.tokenize = null; |
| 104 | return ret("string", "string"); |
| 105 | }; |
| 106 | } |
| 107 | |
| 108 | function tokenParenthesized(stream, state) { |
| 109 | stream.next(); // Must be '(' |
no test coverage detected