summaryrefslogtreecommitdiff
path: root/tests/examplefiles/js
diff options
context:
space:
mode:
Diffstat (limited to 'tests/examplefiles/js')
-rw-r--r--tests/examplefiles/js/BOM.js.output2
-rw-r--r--tests/examplefiles/js/evil_regex.js.output252
-rw-r--r--tests/examplefiles/js/general.js.output355
-rw-r--r--tests/examplefiles/js/regex.js.output88
-rw-r--r--tests/examplefiles/js/unicode.js.output20
5 files changed, 358 insertions, 359 deletions
diff --git a/tests/examplefiles/js/BOM.js.output b/tests/examplefiles/js/BOM.js.output
index 54fd6a72..9cc7e0ee 100644
--- a/tests/examplefiles/js/BOM.js.output
+++ b/tests/examplefiles/js/BOM.js.output
@@ -1,3 +1,3 @@
'' Text
'/* There is a BOM at the beginning of this file. */' Comment.Multiline
-'\n' Text
+'\n' Text.Whitespace
diff --git a/tests/examplefiles/js/evil_regex.js.output b/tests/examplefiles/js/evil_regex.js.output
index 81c9f9dc..6590b08e 100644
--- a/tests/examplefiles/js/evil_regex.js.output
+++ b/tests/examplefiles/js/evil_regex.js.output
@@ -5,33 +5,35 @@
'(' Punctuation
'foo' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'||' Operator
-' ' Text
+' ' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'[' Punctuation
'/regexp/' Literal.String.Regex
',' Punctuation
'/regexp/' Literal.String.Regex
',' Punctuation
-' ' Text
+' ' Text.Whitespace
'/regexp/' Literal.String.Regex
',' Punctuation
-' ' Text
-'// comment\n' Comment.Single
+' ' Text.Whitespace
+'// comment' Comment.Single
+'\n' Text.Whitespace
-'// comment\n' Comment.Single
+'// comment' Comment.Single
+'\n' Text.Whitespace
'/regexp/' Literal.String.Regex
']' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'if' Keyword
-' ' Text
+' ' Text.Whitespace
'(' Punctuation
'/regexp/' Literal.String.Regex
'.' Punctuation
@@ -40,7 +42,7 @@
'string' Name.Other
')' Punctuation
')' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'{' Punctuation
'/regexp/' Literal.String.Regex
@@ -52,25 +54,25 @@
';' Punctuation
'}' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
'/regexp/' Literal.String.Regex
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'/regexp/' Literal.String.Regex
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'if' Keyword
-' ' Text
+' ' Text.Whitespace
'(' Punctuation
'0' Literal.Number.Float
'<' Operator
@@ -80,9 +82,9 @@
'(' Punctuation
'string' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'||' Operator
-' ' Text
+' ' Text.Whitespace
'1' Literal.Number.Float
'>' Operator
'/regexp/' Literal.String.Regex
@@ -92,27 +94,27 @@
'string' Name.Other
')' Punctuation
')' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'{' Punctuation
-' ' Text
+' ' Text.Whitespace
'u' Name.Other
':' Operator
'/regexp/' Literal.String.Regex
',' Punctuation
-' ' Text
+' ' Text.Whitespace
'v' Name.Other
':' Operator
-' ' Text
+' ' Text.Whitespace
'/regexp/' Literal.String.Regex
-' ' Text
+' ' Text.Whitespace
'}' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'foo' Name.Other
'(' Punctuation
@@ -125,7 +127,7 @@
'string' Name.Other
')' Punctuation
';' Punctuation
-' ' Text
+' ' Text.Whitespace
'/regexp/' Literal.String.Regex
'.' Punctuation
'test' Name.Other
@@ -133,27 +135,27 @@
'string' Name.Other
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'if' Keyword
-' ' Text
+' ' Text.Whitespace
'(' Punctuation
'!' Operator
'/regexp/' Literal.String.Regex
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'foobar' Name.Other
'(' Punctuation
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'u' Name.Other
-' ' Text
+' ' Text.Whitespace
'%' Operator
'/regexp/' Literal.String.Regex
'.' Punctuation
@@ -161,7 +163,7 @@
'(' Punctuation
'string' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'*' Operator
'/regexp/' Literal.String.Regex
'.' Punctuation
@@ -169,9 +171,9 @@
'(' Punctuation
'string' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'/' Operator
-' ' Text
+' ' Text.Whitespace
'/regexp/' Literal.String.Regex
'.' Punctuation
'exec' Name.Other
@@ -179,12 +181,12 @@
'string' Name.Other
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'u' Name.Other
'?' Operator
'/regexp/' Literal.String.Regex
@@ -193,11 +195,11 @@
'(' Punctuation
'string' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
':' Operator
-' ' Text
+' ' Text.Whitespace
'v' Name.Other
-' ' Text
+' ' Text.Whitespace
'+' Operator
'/regexp/' Literal.String.Regex
'.' Punctuation
@@ -205,7 +207,7 @@
'(' Punctuation
'string' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'-' Operator
'/regexp/' Literal.String.Regex
'.' Punctuation
@@ -214,12 +216,12 @@
'string' Name.Other
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'a' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'u' Name.Other
'^' Operator
'/regexp/' Literal.String.Regex
@@ -228,7 +230,7 @@
'(' Punctuation
'string' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'&' Operator
'/regexp/' Literal.String.Regex
'.' Punctuation
@@ -236,7 +238,7 @@
'(' Punctuation
'string' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'|' Operator
'/regexp/' Literal.String.Regex
'.' Punctuation
@@ -244,7 +246,7 @@
'(' Punctuation
'string' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'+' Operator
'~' Operator
'/regexp/' Literal.String.Regex
@@ -254,114 +256,112 @@
'string' Name.Other
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'/regexp/' Literal.String.Regex
-' ' Text
+' ' Text.Whitespace
'/* a comment */' Comment.Multiline
-' ' Text
+' ' Text.Whitespace
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'/[reg/exp]/' Literal.String.Regex
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'4' Literal.Number.Float
'/' Operator
'2' Literal.Number.Float
'/' Operator
'i' Name.Other
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'(' Punctuation
'a' Name.Other
-' ' Text
+' ' Text.Whitespace
'==' Operator
-' ' Text
+' ' Text.Whitespace
'b' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'?' Operator
'/* this is a comment */' Comment.Multiline
-' ' Text
+' ' Text.Whitespace
'c' Name.Other
-' ' Text
+' ' Text.Whitespace
':' Operator
-' ' Text
+' ' Text.Whitespace
'd' Name.Other
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
-'/// a comment //\n' Comment.Single
+'/// a comment //' Comment.Single
+'\n' Text.Whitespace
'a' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'/regex/' Literal.String.Regex
'/' Operator
'2' Literal.Number.Float
'/' Operator
'1' Literal.Number.Float
';' Punctuation
-' ' Text
-'//syntactically correct, returns NaN\n' Comment.Single
-
-'\n\n\n\n' Text
+' ' Text.Whitespace
+'//syntactically correct, returns NaN' Comment.Single
+'\n\n\n\n\n' Text.Whitespace
'/* original examples */' Comment.Multiline
-'\n\n' Text
-
-'// regex\n' Comment.Single
+'\n\n' Text.Whitespace
-'\n' Text
+'// regex' Comment.Single
+'\n\n' Text.Whitespace
'blah' Name.Other
'(' Punctuation
'/abc/' Literal.String.Regex
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'/abc/' Literal.String.Regex
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'/abc/' Literal.String.Regex
'.' Punctuation
'match' Name.Other
';' Punctuation
-'\n\n' Text
-
-'// math\n' Comment.Single
+'\n\n' Text.Whitespace
-'\n' Text
+'// math' Comment.Single
+'\n\n' Text.Whitespace
'blah' Name.Other
'(' Punctuation
@@ -370,46 +370,46 @@
'2' Literal.Number.Float
')' Punctuation
';' Punctuation
-' ' Text
-'//comment\n' Comment.Single
+' ' Text.Whitespace
+'//comment' Comment.Single
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'1' Literal.Number.Float
-' ' Text
+' ' Text.Whitespace
'/' Operator
-' ' Text
+' ' Text.Whitespace
'2' Literal.Number.Float
-' ' Text
+' ' Text.Whitespace
'/' Operator
-' ' Text
+' ' Text.Whitespace
'3' Literal.Number.Float
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'1' Literal.Number.Float
'/' Operator
'1' Literal.Number.Float
'/' Operator
'.1' Literal.Number.Float
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
-'// broken\n' Comment.Single
-
-'\n' Text
+'// broken' Comment.Single
+'\n\n' Text.Whitespace
'x' Name.Other
'=' Operator
'/1/' Literal.String.Regex
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
'=' Operator
@@ -419,7 +419,7 @@
'/' Operator
'g' Name.Other
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
'=' Operator
@@ -429,18 +429,17 @@
'/' Operator
'g' Name.Other
';' Punctuation
-'\n\n' Text
-
-'// real-world\n' Comment.Single
+'\n\n' Text.Whitespace
-'\n' Text
+'// real-world' Comment.Single
+'\n\n' Text.Whitespace
'var' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'1' Literal.Number.Float
'/' Operator
'(' Punctuation
@@ -454,28 +453,29 @@
')' Punctuation
')' Punctuation
';' Punctuation
-' ' Text
-'// convert to number between 1-0\n' Comment.Single
+' ' Text.Whitespace
+'// convert to number between 1-0' Comment.Single
+'\n' Text.Whitespace
'return' Keyword
-' ' Text
+' ' Text.Whitespace
'Math' Name.Builtin
'.' Punctuation
'round' Name.Other
'(' Punctuation
'(' Punctuation
'num' Name.Other
-' ' Text
+' ' Text.Whitespace
'/' Operator
-' ' Text
+' ' Text.Whitespace
'den' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'*' Operator
-' ' Text
+' ' Text.Whitespace
'100' Literal.Number.Float
')' Punctuation
'/' Operator
'100' Literal.Number.Float
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
diff --git a/tests/examplefiles/js/general.js.output b/tests/examplefiles/js/general.js.output
index 14531fd1..4b5c98e2 100644
--- a/tests/examplefiles/js/general.js.output
+++ b/tests/examplefiles/js/general.js.output
@@ -1,72 +1,73 @@
'' Text
-'// Most examples from https://github.com/rse/es6-features under MIT license\n' Comment.Single
+'// Most examples from https://github.com/rse/es6-features under MIT license' Comment.Single
+'\n' Text.Whitespace
'const' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'PI' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'3.141593' Literal.Number.Float
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'let' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'callbacks' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'[' Punctuation
']' Punctuation
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'odds' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'evens' Name.Other
'.' Punctuation
'map' Name.Other
'(' Punctuation
'v' Name.Other
-' ' Text
+' ' Text.Whitespace
'=>' Punctuation
-' ' Text
+' ' Text.Whitespace
'v' Name.Other
-' ' Text
+' ' Text.Whitespace
'+' Operator
-' ' Text
+' ' Text.Whitespace
'1' Literal.Number.Float
')' Punctuation
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'nums' Name.Other
'.' Punctuation
'forEach' Name.Other
'(' Punctuation
'v' Name.Other
-' ' Text
+' ' Text.Whitespace
'=>' Punctuation
-' ' Text
+' ' Text.Whitespace
'{' Punctuation
-'\n ' Text
+'\n ' Text.Whitespace
'if' Keyword
-' ' Text
+' ' Text.Whitespace
'(' Punctuation
'v' Name.Other
-' ' Text
+' ' Text.Whitespace
'%' Operator
-' ' Text
+' ' Text.Whitespace
'5' Literal.Number.Float
-' ' Text
+' ' Text.Whitespace
'===' Operator
-' ' Text
+' ' Text.Whitespace
'0' Literal.Number.Float
')' Punctuation
-'\n ' Text
+'\n ' Text.Whitespace
'fives' Name.Other
'.' Punctuation
'push' Name.Other
@@ -74,188 +75,188 @@
'v' Name.Other
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'}' Punctuation
')' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'function' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'f' Name.Other
-' ' Text
+' ' Text.Whitespace
'(' Punctuation
'x' Name.Other
',' Punctuation
-' ' Text
+' ' Text.Whitespace
'y' Name.Other
',' Punctuation
-' ' Text
+' ' Text.Whitespace
'...' Punctuation
'a' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'{' Punctuation
-'\n ' Text
+'\n ' Text.Whitespace
'return' Keyword
-' ' Text
+' ' Text.Whitespace
'(' Punctuation
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'+' Operator
-' ' Text
+' ' Text.Whitespace
'y' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'*' Operator
-' ' Text
+' ' Text.Whitespace
'a' Name.Other
'.' Punctuation
'length' Name.Other
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'}' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'var' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'params' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'[' Punctuation
-' ' Text
+' ' Text.Whitespace
'"hello"' Literal.String.Double
',' Punctuation
-' ' Text
+' ' Text.Whitespace
'true' Keyword.Constant
',' Punctuation
-' ' Text
+' ' Text.Whitespace
'7' Literal.Number.Float
-' ' Text
+' ' Text.Whitespace
']' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'var' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'other' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'[' Punctuation
-' ' Text
+' ' Text.Whitespace
'1' Literal.Number.Float
',' Punctuation
-' ' Text
+' ' Text.Whitespace
'2' Literal.Number.Float
',' Punctuation
-' ' Text
+' ' Text.Whitespace
'...' Punctuation
'params' Name.Other
-' ' Text
+' ' Text.Whitespace
']' Punctuation
';' Punctuation
-' ' Text
-'// [ 1, 2, "hello", true, 7 ]\n' Comment.Single
+' ' Text.Whitespace
+'// [ 1, 2, "hello", true, 7 ]' Comment.Single
+'\n' Text.Whitespace
'f' Name.Other
'(' Punctuation
'1' Literal.Number.Float
',' Punctuation
-' ' Text
+' ' Text.Whitespace
'2' Literal.Number.Float
',' Punctuation
-' ' Text
+' ' Text.Whitespace
'...' Punctuation
'params' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'===' Operator
-' ' Text
+' ' Text.Whitespace
'9' Literal.Number.Float
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'var' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'str' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'"foo"' Literal.String.Double
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'var' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'chars' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'[' Punctuation
-' ' Text
+' ' Text.Whitespace
'...' Punctuation
'str' Name.Other
-' ' Text
+' ' Text.Whitespace
']' Punctuation
';' Punctuation
-' ' Text
-'// [ "f", "o", "o" ]\n' Comment.Single
-
-'\n' Text
+' ' Text.Whitespace
+'// [ "f", "o", "o" ]' Comment.Single
+'\n\n' Text.Whitespace
'var' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'customer' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'{' Punctuation
-' ' Text
+' ' Text.Whitespace
'name' Name.Other
':' Operator
-' ' Text
+' ' Text.Whitespace
'"Foo"' Literal.String.Double
-' ' Text
+' ' Text.Whitespace
'}' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'var' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'card' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'{' Punctuation
-' ' Text
+' ' Text.Whitespace
'amount' Name.Other
':' Operator
-' ' Text
+' ' Text.Whitespace
'7' Literal.Number.Float
',' Punctuation
-' ' Text
+' ' Text.Whitespace
'product' Name.Other
':' Operator
-' ' Text
+' ' Text.Whitespace
'"Bar"' Literal.String.Double
',' Punctuation
-' ' Text
+' ' Text.Whitespace
'unitprice' Name.Other
':' Operator
-' ' Text
+' ' Text.Whitespace
'42' Literal.Number.Float
-' ' Text
+' ' Text.Whitespace
'}' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'message' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'`' Literal.String.Backtick
'Hello ' Literal.String.Backtick
'${' Literal.String.Interpol
@@ -280,9 +281,9 @@
'card' Name.Other
'.' Punctuation
'amount' Name.Other
-' ' Text
+' ' Text.Whitespace
'*' Operator
-' ' Text
+' ' Text.Whitespace
'card' Name.Other
'.' Punctuation
'unitprice' Name.Other
@@ -290,36 +291,36 @@
' bucks?' Literal.String.Backtick
'`' Literal.String.Backtick
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'0b111110111' Literal.Number.Bin
-' ' Text
+' ' Text.Whitespace
'===' Operator
-' ' Text
+' ' Text.Whitespace
'503' Literal.Number.Float
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'0o767' Literal.Number.Oct
-' ' Text
+' ' Text.Whitespace
'===' Operator
-' ' Text
+' ' Text.Whitespace
'503' Literal.Number.Float
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'for' Keyword
-' ' Text
+' ' Text.Whitespace
'(' Punctuation
'let' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'codepoint' Name.Other
-' ' Text
+' ' Text.Whitespace
'of' Keyword
-' ' Text
+' ' Text.Whitespace
'"𠮷"' Literal.String.Double
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'console' Name.Other
'.' Punctuation
'log' Name.Other
@@ -327,140 +328,140 @@
'codepoint' Name.Other
')' Punctuation
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'function' Keyword.Declaration
'*' Operator
-' ' Text
+' ' Text.Whitespace
'(' Punctuation
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'*' Operator
'function' Keyword.Declaration
'(' Punctuation
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'yield' Keyword
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'export' Keyword
-' ' Text
+' ' Text.Whitespace
'class' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'Node' Name.Other
-' ' Text
+' ' Text.Whitespace
'{' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'}' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'class' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'A' Name.Other
-' ' Text
+' ' Text.Whitespace
'{' Punctuation
-'\n ' Text
+'\n ' Text.Whitespace
'constructor' Keyword.Reserved
'(' Punctuation
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'{' Punctuation
-'\n ' Text
+'\n ' Text.Whitespace
'super' Keyword
'(' Punctuation
')' Punctuation
-'\n ' Text
+'\n ' Text.Whitespace
'}' Punctuation
-'\n\n ' Text
+'\n\n ' Text.Whitespace
'constructor' Keyword.Reserved
'(' Punctuation
'test' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'{' Punctuation
-'\n ' Text
+'\n ' Text.Whitespace
'super' Keyword
'(' Punctuation
'test' Name.Other
')' Punctuation
';' Punctuation
-'\n ' Text
+'\n ' Text.Whitespace
'}' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'}' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'isFinite' Name.Builtin
'(' Punctuation
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'isNaN' Name.Builtin
'(' Punctuation
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'new' Operator.Word
-' ' Text
+' ' Text.Whitespace
'Promise' Name.Builtin
'(' Punctuation
'...' Punctuation
'a' Name.Other
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'new' Operator.Word
-' ' Text
+' ' Text.Whitespace
'Proxy' Name.Builtin
'(' Punctuation
'...' Punctuation
'a' Name.Other
')' Punctuation
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'??=' Operator
-' ' Text
+' ' Text.Whitespace
'1' Literal.Number.Float
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'&&=' Operator
-' ' Text
+' ' Text.Whitespace
'2' Literal.Number.Float
-' ' Text
+' ' Text.Whitespace
'??' Operator
-' ' Text
+' ' Text.Whitespace
'3' Literal.Number.Float
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'**=' Operator
-' ' Text
+' ' Text.Whitespace
'2' Literal.Number.Float
'**' Operator
'3' Literal.Number.Float
@@ -469,67 +470,67 @@
'&' Operator
'4' Literal.Number.Float
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'||=' Operator
-' ' Text
+' ' Text.Whitespace
'2' Literal.Number.Float
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'throw' Keyword
-' ' Text
+' ' Text.Whitespace
'new' Operator.Word
-' ' Text
+' ' Text.Whitespace
'Error' Name.Exception
'(' Punctuation
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'throw' Keyword
-' ' Text
+' ' Text.Whitespace
'new' Operator.Word
-' ' Text
+' ' Text.Whitespace
'TypeError' Name.Exception
'(' Punctuation
')' Punctuation
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'new' Operator.Word
-' ' Text
+' ' Text.Whitespace
'Uint8ClampedArray' Name.Builtin
'(' Punctuation
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'new' Operator.Word
-' ' Text
+' ' Text.Whitespace
'DataView' Name.Builtin
'(' Punctuation
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'new' Operator.Word
-' ' Text
+' ' Text.Whitespace
'Map' Name.Builtin
'(' Punctuation
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'new' Operator.Word
-' ' Text
+' ' Text.Whitespace
'WeakMap' Name.Builtin
'(' Punctuation
')' Punctuation
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'Intl' Name.Builtin
'.' Punctuation
@@ -537,20 +538,20 @@
'(' Punctuation
')' Punctuation
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'globalThis' Name.Builtin
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'window' Name.Builtin
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'global' Name.Builtin
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'this' Keyword
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
diff --git a/tests/examplefiles/js/regex.js.output b/tests/examplefiles/js/regex.js.output
index a386eae5..f92863ae 100644
--- a/tests/examplefiles/js/regex.js.output
+++ b/tests/examplefiles/js/regex.js.output
@@ -1,36 +1,34 @@
'' Text
-'// regex\n' Comment.Single
-
-'\n' Text
+'// regex' Comment.Single
+'\n\n' Text.Whitespace
'blah' Name.Other
'(' Punctuation
'/abc/' Literal.String.Regex
')' Punctuation
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'/abc/' Literal.String.Regex
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'/abc/' Literal.String.Regex
'.' Punctuation
'match' Name.Other
';' Punctuation
-'\n\n' Text
-
-'// math\n' Comment.Single
+'\n\n' Text.Whitespace
-'\n' Text
+'// math' Comment.Single
+'\n\n' Text.Whitespace
'blah' Name.Other
'(' Punctuation
@@ -39,46 +37,46 @@
'2' Literal.Number.Float
')' Punctuation
';' Punctuation
-' ' Text
-'//comment\n' Comment.Single
+' ' Text.Whitespace
+'//comment' Comment.Single
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'1' Literal.Number.Float
-' ' Text
+' ' Text.Whitespace
'/' Operator
-' ' Text
+' ' Text.Whitespace
'2' Literal.Number.Float
-' ' Text
+' ' Text.Whitespace
'/' Operator
-' ' Text
+' ' Text.Whitespace
'3' Literal.Number.Float
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'1' Literal.Number.Float
'/' Operator
'1' Literal.Number.Float
'/' Operator
'.1' Literal.Number.Float
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
-'// broken\n' Comment.Single
-
-'\n' Text
+'// broken' Comment.Single
+'\n\n' Text.Whitespace
'x' Name.Other
'=' Operator
'/1/' Literal.String.Regex
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
'=' Operator
@@ -88,7 +86,7 @@
'/' Operator
'g' Name.Other
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'x' Name.Other
'=' Operator
@@ -98,18 +96,17 @@
'/' Operator
'g' Name.Other
';' Punctuation
-'\n\n' Text
-
-'// real-world\n' Comment.Single
+'\n\n' Text.Whitespace
-'\n' Text
+'// real-world' Comment.Single
+'\n\n' Text.Whitespace
'var' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'x' Name.Other
-' ' Text
+' ' Text.Whitespace
'=' Operator
-' ' Text
+' ' Text.Whitespace
'1' Literal.Number.Float
'/' Operator
'(' Punctuation
@@ -123,28 +120,29 @@
')' Punctuation
')' Punctuation
';' Punctuation
-' ' Text
-'// convert to number between 1-0\n' Comment.Single
+' ' Text.Whitespace
+'// convert to number between 1-0' Comment.Single
+'\n' Text.Whitespace
'return' Keyword
-' ' Text
+' ' Text.Whitespace
'Math' Name.Builtin
'.' Punctuation
'round' Name.Other
'(' Punctuation
'(' Punctuation
'num' Name.Other
-' ' Text
+' ' Text.Whitespace
'/' Operator
-' ' Text
+' ' Text.Whitespace
'den' Name.Other
')' Punctuation
-' ' Text
+' ' Text.Whitespace
'*' Operator
-' ' Text
+' ' Text.Whitespace
'100' Literal.Number.Float
')' Punctuation
'/' Operator
'100' Literal.Number.Float
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
diff --git a/tests/examplefiles/js/unicode.js.output b/tests/examplefiles/js/unicode.js.output
index 98bb080e..6f19ac9c 100644
--- a/tests/examplefiles/js/unicode.js.output
+++ b/tests/examplefiles/js/unicode.js.output
@@ -1,29 +1,29 @@
'var' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'école' Name.Other
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'var' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'sinθ' Name.Other
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'var' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'เมือง' Name.Other
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace
'var' Keyword.Declaration
-' ' Text
+' ' Text.Whitespace
'a\\u1234b' Name.Other
';' Punctuation
-'\n\n' Text
+'\n\n' Text.Whitespace
'var' Keyword.Declaration
-'\u2008' Text
+'\u2008' Text.Whitespace
'nbsp' Name.Other
';' Punctuation
-'\n' Text
+'\n' Text.Whitespace