simplify comment definition

This commit is contained in:
Camden Cheek 2021-06-20 12:46:57 -06:00
parent 23ca71644d
commit d4f9099f9a
No known key found for this signature in database
GPG key ID: 595BFFE3A04E48B9
3 changed files with 3111 additions and 3121 deletions

View file

@ -50,10 +50,7 @@ module.exports = grammar({
), ),
label_instruction: ($) => label_instruction: ($) =>
seq( seq(alias(/[lL][aA][bB][eE][lL]/, "LABEL"), repeat1($.label_pair)),
alias(/[lL][aA][bB][eE][lL]/, "LABEL"),
repeat1($.label_pair)
),
expose_instruction: ($) => expose_instruction: ($) =>
seq( seq(
@ -214,8 +211,7 @@ module.exports = grammar({
) )
), ),
image_name: ($) => image_name: ($) => repeat1(choice(/[^@:\s\$]+/, $.expansion)),
repeat1(choice(/[^@:\s\$]+/, $.expansion)),
image_tag: ($) => image_tag: ($) =>
seq( seq(
@ -298,6 +294,6 @@ module.exports = grammar({
_non_newline_whitespace: ($) => /[\t ]+/, _non_newline_whitespace: ($) => /[\t ]+/,
comment: ($) => seq("#", /.*/), comment: ($) => /#.*/,
}, },
}); });

View file

@ -1409,17 +1409,8 @@
"value": "[\\t ]+" "value": "[\\t ]+"
}, },
"comment": { "comment": {
"type": "SEQ", "type": "PATTERN",
"members": [ "value": "#.*"
{
"type": "STRING",
"value": "#"
},
{
"type": "PATTERN",
"value": ".*"
}
]
} }
}, },
"extras": [ "extras": [

File diff suppressed because it is too large Load diff