mirror of
https://github.com/ralsina/tartrazine.git
synced 2024-11-10 13:32:24 +00:00
78 lines
1.5 KiB
Plaintext
78 lines
1.5 KiB
Plaintext
|
---input---
|
||
|
[Section A]
|
||
|
KeyOne=value 1
|
||
|
KeyTwo=value 2
|
||
|
|
||
|
# a comment
|
||
|
|
||
|
[Section B]
|
||
|
Setting="something" "some thing" "…"
|
||
|
KeyTwo=value 2 \
|
||
|
value 2 continued
|
||
|
|
||
|
[Section C]
|
||
|
KeyThree=value 3\
|
||
|
# this line is ignored
|
||
|
; this line is ignored too
|
||
|
value 3 continued
|
||
|
|
||
|
---tokens---
|
||
|
'[Section A]' Keyword
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
'KeyOne' Name.Attribute
|
||
|
'=' Operator
|
||
|
'value 1' Literal.String
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
'KeyTwo' Name.Attribute
|
||
|
'=' Operator
|
||
|
'value 2' Literal.String
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
'# a comment' Comment.Single
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
'[Section B]' Keyword
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
'Setting' Name.Attribute
|
||
|
'=' Operator
|
||
|
'"something" "some thing" "…"' Literal.String
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
'KeyTwo' Name.Attribute
|
||
|
'=' Operator
|
||
|
'value 2 ' Literal.String
|
||
|
'\\' Text
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
' ' Text.Whitespace
|
||
|
'value 2 continued' Literal.String
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
'[Section C]' Keyword
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
'KeyThree' Name.Attribute
|
||
|
'=' Operator
|
||
|
'value 3' Literal.String
|
||
|
'\\' Text
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
'# this line is ignored' Comment.Single
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
'; this line is ignored too' Comment.Single
|
||
|
'\n' Text.Whitespace
|
||
|
|
||
|
' ' Text.Whitespace
|
||
|
'value 3 continued' Literal.String
|
||
|
'\n' Text.Whitespace
|