Skip to content

Commit

Permalink
Rip: Fixed some regexp + moved down numbers
Browse files Browse the repository at this point in the history
  • Loading branch information
Golmote committed Aug 30, 2015
1 parent e6c6b85 commit 1093f7d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
11 changes: 5 additions & 6 deletions components/prism-rip.js
Original file line number Diff line number Diff line change
@@ -1,27 +1,26 @@
Prism.languages.rip = {
'comment': /#[^\r\n]*(\r?\n|$)/,
'comment': /#.*/,

'keyword': /(?:=>|->)|\b(?:class|if|else|switch|case|return|exit|try|catch|finally|raise)\b/,

'builtin': /\b(@|System)\b/,
'builtin': /@|\bSystem\b/,

'boolean': /\b(true|false)\b/,
'boolean': /\b(?:true|false)\b/,

'date': /\b\d{4}-\d{2}-\d{2}\b/,
'time': /\b\d{2}:\d{2}:\d{2}\b/,
'datetime': /\b\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\b/,

'number': /[+-]?(?:(?:\d+\.\d+)|(?:\d+))/,

'character': /\B`[^\s`'",.:;#\/\\()<>\[\]{}]\b/,

'regex': {
pattern: /(^|[^/])\/(?!\/)(\[.+?]|\\.|[^/\r\n])+\/(?=\s*($|[\r\n,.;})]))/,
pattern: /(^|[^/])\/(?!\/)(\[.+?]|\\.|[^/\\\r\n])+\/(?=\s*($|[\r\n,.;})]))/,
lookbehind: true
},

'symbol': /:[^\d\s`'",.:;#\/\\()<>\[\]{}][^\s`'",.:;#\/\\()<>\[\]{}]*/,
'string': /("|')(\\?.)*?\1/,
'number': /[+-]?(?:(?:\d+\.\d+)|(?:\d+))/,

'punctuation': /(?:\.{2,3})|[`,.:;=\/\\()<>\[\]{}]/,

Expand Down
2 changes: 1 addition & 1 deletion components/prism-rip.min.js

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

0 comments on commit 1093f7d

Please sign in to comment.