use prism-tomorrow.css

This commit is contained in:
CyC2018
2018-12-19 14:09:39 +08:00
parent 0f00bcacaf
commit e9e604e6a7
1747 changed files with 100462 additions and 0 deletions

View File

@ -0,0 +1,12 @@
true; false;
----------------------------------------------------
[
["boolean", "true"], ["punctuation", ";"],
["boolean", "false"], ["punctuation", ";"]
]
----------------------------------------------------
Checks for booleans.

View File

@ -0,0 +1,53 @@
class Foo
interface bar
extends Foo
implements bar
trait Foo
instanceof \bar
new \Foo
catch (bar)
----------------------------------------------------
[
"class ",
["class-name", [
"Foo"
]],
"\r\ninterface ",
["class-name", [
"bar"
]],
"\r\nextends ",
["class-name", [
"Foo"
]],
"\r\nimplements ",
["class-name", [
"bar"
]],
"\r\ntrait ",
["class-name", [
"Foo"
]],
["keyword", "instanceof"],
["class-name", [
["punctuation", "\\"],
"bar"
]],
["keyword", "new"],
["class-name", [
["punctuation", "\\"],
"Foo"
]],
["keyword", "catch"],
["punctuation", "("],
["class-name", [
"bar"
]],
["punctuation", ")"]
]
----------------------------------------------------
Checks for class names.

View File

@ -0,0 +1,16 @@
// foobar
/**/
/* foo
bar */
----------------------------------------------------
[
["comment", "// foobar"],
["comment", "/**/"],
["comment", "/* foo\r\nbar */"]
]
----------------------------------------------------
Checks for single-line and multi-line comments.

View File

@ -0,0 +1,23 @@
foo()
foo_bar()
f42()
----------------------------------------------------
[
["function", "foo"],
["punctuation", "("],
["punctuation", ")"],
["function", "foo_bar"],
["punctuation", "("],
["punctuation", ")"],
["function", "f42"],
["punctuation", "("],
["punctuation", ")"]
]
----------------------------------------------------
Checks for functions.

View File

@ -0,0 +1,13 @@
/*
//
*/
----------------------------------------------------
[
["comment", "/*\r\n//\r\n*/"]
]
----------------------------------------------------
Non-regression test for inline comments inside multiline comments. See #1340

View File

@ -0,0 +1,30 @@
if; else; while; do; for;
return; in; instanceof; function; new;
try; throw; catch; finally; null;
break; continue;
----------------------------------------------------
[
["keyword", "if"], ["punctuation", ";"],
["keyword", "else"], ["punctuation", ";"],
["keyword", "while"], ["punctuation", ";"],
["keyword", "do"], ["punctuation", ";"],
["keyword", "for"], ["punctuation", ";"],
["keyword", "return"], ["punctuation", ";"],
["keyword", "in"], ["punctuation", ";"],
["keyword", "instanceof"], ["punctuation", ";"],
["keyword", "function"], ["punctuation", ";"],
["keyword", "new"], ["punctuation", ";"],
["keyword", "try"], ["punctuation", ";"],
["keyword", "throw"], ["punctuation", ";"],
["keyword", "catch"], ["punctuation", ";"],
["keyword", "finally"], ["punctuation", ";"],
["keyword", "null"], ["punctuation", ";"],
["keyword", "break"], ["punctuation", ";"],
["keyword", "continue"], ["punctuation", ";"]
]
----------------------------------------------------
Checks for all keywords.

View File

@ -0,0 +1,23 @@
42
3.14159
4e10
2.1e-10
0.4e+2
0xbabe
0xBABE
----------------------------------------------------
[
["number", "42"],
["number", "3.14159"],
["number", "4e10"],
["number", "2.1e-10"],
["number", "0.4e+2"],
["number", "0xbabe"],
["number", "0xBABE"]
]
----------------------------------------------------
Checks for decimal numbers and hexadecimal numbers.

View File

@ -0,0 +1,21 @@
- + -- ++
< <= > >=
= == ===
! != !==
& && | ||
? * / ~ ^ %
----------------------------------------------------
[
["operator", "-"], ["operator", "+"], ["operator", "--"], ["operator", "++"],
["operator", "<"], ["operator", "<="], ["operator", ">"], ["operator", ">="],
["operator", "="], ["operator", "=="], ["operator", "==="],
["operator", "!"], ["operator", "!="], ["operator", "!=="],
["operator", "&"], ["operator", "&&"], ["operator", "|"], ["operator", "||"],
["operator", "?"], ["operator", "*"], ["operator", "/"], ["operator", "~"], ["operator", "^"], ["operator", "%"]
]
----------------------------------------------------
Checks for all operators.

View File

@ -0,0 +1,31 @@
""
''
"f\"oo"
'b\'ar'
"foo\
bar"
'foo\
bar'
"foo /* comment */ bar"
'foo // bar'
'foo // bar' //comment
----------------------------------------------------
[
["string", "\"\""],
["string", "''"],
["string", "\"f\\\"oo\""],
["string", "'b\\'ar'"],
["string", "\"foo\\\r\nbar\""],
["string", "'foo\\\r\nbar'"],
["string", "\"foo /* comment */ bar\""],
["string", "'foo // bar'"],
["string", "'foo // bar'"],
["comment", "//comment"]
]
----------------------------------------------------
Checks for empty strings, single-line strings and
multi-line strings, both single-quoted and double-quoted.