diff options
author | Kruti Shah | 2012-07-17 12:40:00 -0700 |
---|---|---|
committer | Kruti Shah | 2012-07-17 12:40:00 -0700 |
commit | bf2d7bdb22c28089dc1067bc9094ebc590daac87 (patch) | |
tree | 2156d9920ea1b7db49ed6460545fea7cda121bae /imports/codemirror/mode/clike/clike.js | |
parent | 7e2c2dbd040ed79a3f0678f91bd4b6db9cf69231 (diff) | |
parent | b4b3e45d6684e77d361b4f8ca5be4889428320c5 (diff) | |
download | ninja-bf2d7bdb22c28089dc1067bc9094ebc590daac87.tar.gz |
Merge branch 'refs/heads/TimelineUberJD' into Timeline-local-kruti
Diffstat (limited to 'imports/codemirror/mode/clike/clike.js')
-rw-r--r-- | imports/codemirror/mode/clike/clike.js | 39 |
1 files changed, 38 insertions, 1 deletions
diff --git a/imports/codemirror/mode/clike/clike.js b/imports/codemirror/mode/clike/clike.js index 66443fb8..0e7f48b6 100644 --- a/imports/codemirror/mode/clike/clike.js +++ b/imports/codemirror/mode/clike/clike.js | |||
@@ -21,7 +21,7 @@ CodeMirror.defineMode("clike", function(config, parserConfig) { | |||
21 | } | 21 | } |
22 | if (/[\[\]{}\(\),;\:\.]/.test(ch)) { | 22 | if (/[\[\]{}\(\),;\:\.]/.test(ch)) { |
23 | curPunc = ch; | 23 | curPunc = ch; |
24 | return null | 24 | return null; |
25 | } | 25 | } |
26 | if (/\d/.test(ch)) { | 26 | if (/\d/.test(ch)) { |
27 | stream.eatWhile(/[\w\.]/); | 27 | stream.eatWhile(/[\w\.]/); |
@@ -231,4 +231,41 @@ CodeMirror.defineMode("clike", function(config, parserConfig) { | |||
231 | } | 231 | } |
232 | } | 232 | } |
233 | }); | 233 | }); |
234 | CodeMirror.defineMIME("text/x-scala", { | ||
235 | name: "clike", | ||
236 | keywords: words( | ||
237 | |||
238 | /* scala */ | ||
239 | "abstract case catch class def do else extends false final finally for forSome if " + | ||
240 | "implicit import lazy match new null object override package private protected return " + | ||
241 | "sealed super this throw trait try trye type val var while with yield _ : = => <- <: " + | ||
242 | "<% >: # @ " + | ||
243 | |||
244 | /* package scala */ | ||
245 | "assert assume require print println printf readLine readBoolean readByte readShort " + | ||
246 | "readChar readInt readLong readFloat readDouble " + | ||
247 | |||
248 | "AnyVal App Application Array BufferedIterator BigDecimal BigInt Char Console Either " + | ||
249 | "Enumeration Equiv Error Exception Fractional Function IndexedSeq Integral Iterable " + | ||
250 | "Iterator List Map Numeric Nil NotNull Option Ordered Ordering PartialFunction PartialOrdering " + | ||
251 | "Product Proxy Range Responder Seq Serializable Set Specializable Stream StringBuilder " + | ||
252 | "StringContext Symbol Throwable Traversable TraversableOnce Tuple Unit Vector :: #:: " + | ||
253 | |||
254 | /* package java.lang */ | ||
255 | "Boolean Byte Character CharSequence Class ClassLoader Cloneable Comparable " + | ||
256 | "Compiler Double Exception Float Integer Long Math Number Object Package Pair Process " + | ||
257 | "Runtime Runnable SecurityManager Short StackTraceElement StrictMath String " + | ||
258 | "StringBuffer System Thread ThreadGroup ThreadLocal Throwable Triple Void" | ||
259 | |||
260 | |||
261 | ), | ||
262 | blockKeywords: words("catch class do else finally for forSome if match switch try while"), | ||
263 | atoms: words("true false null"), | ||
264 | hooks: { | ||
265 | "@": function(stream, state) { | ||
266 | stream.eatWhile(/[\w\$_]/); | ||
267 | return "meta"; | ||
268 | } | ||
269 | } | ||
270 | }); | ||
234 | }()); | 271 | }()); |