Explorar o código

Allow the 's' flag in regular expressions

Sebastian Pahnke %!s(int64=6) %!d(string=hai) anos
pai
achega
3e6c3ee653
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/typescript/typescript.ts

+ 1 - 1
src/typescript/typescript.ts

@@ -130,7 +130,7 @@ export const language = {
 			{ include: '@whitespace' },
 
 			// regular expression: ensure it is terminated before beginning (otherwise it is an opeator)
-			[/\/(?=([^\\\/]|\\.)+\/([gimuy]*)(\s*)(\.|;|\/|,|\)|\]|\}|$))/, { token: 'regexp', bracket: '@open', next: '@regexp' }],
+			[/\/(?=([^\\\/]|\\.)+\/([gimsuy]*)(\s*)(\.|;|\/|,|\)|\]|\}|$))/, { token: 'regexp', bracket: '@open', next: '@regexp' }],
 
 			// delimiters and operators
 			[/[()\[\]]/, '@brackets'],