Skip to content

Commit

Permalink
Scala: Simplified patterns
Browse files Browse the repository at this point in the history
  • Loading branch information
Golmote committed Aug 31, 2015
1 parent d49fec0 commit daf2597
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions components/prism-scala.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
Prism.languages.scala = Prism.languages.extend('java', {
'keyword': /(<-|=>)|\b(abstract|case|catch|class|def|do|else|extends|final|finally|for|forSome|if|implicit|import|lazy|match|new|null|object|override|package|private|protected|return|sealed|self|super|this|throw|trait|try|type|val|var|while|with|yield)\b/,
'builtin': /\b(String|Int|Long|Short|Byte|Boolean|Double|Float|Char|Any|AnyRef|AnyVal|Unit|Nothing)\b/,
'number': /\b0x[\da-f]*\.?[\da-f\-]+\b|\b\d*\.?\d+[e]?[\d]*[dfl]?\b/i,
'symbol': /'([^\d\s]\w*)/,
'string': /(""")[\W\w]*?\1|("|\/)[\W\w]*?\2|('.')/
'keyword': /<-|=>|\b(?:abstract|case|catch|class|def|do|else|extends|final|finally|for|forSome|if|implicit|import|lazy|match|new|null|object|override|package|private|protected|return|sealed|self|super|this|throw|trait|try|type|val|var|while|with|yield)\b/,
'string': /"""[\W\w]*?"""|"(?:[^"\\\r\n]|\\.)*"|'(?:[^\\\r\n']|\\.[^\\']*)'/,
'builtin': /\b(?:String|Int|Long|Short|Byte|Boolean|Double|Float|Char|Any|AnyRef|AnyVal|Unit|Nothing)\b/,
'number': /\b(?:0x[\da-f]*\.?[\da-f]+|\d*\.?\d+e?\d*[dfl]?)\b/i,
'symbol': /'[^\d\s\\]\w*/
});
delete Prism.languages.scala['class-name'];
delete Prism.languages.scala['function'];
2 changes: 1 addition & 1 deletion components/prism-scala.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit daf2597

Please sign in to comment.