Remove single-line comment style

This commit is contained in:
Max Brunsfeld 2018-10-28 14:21:26 -07:00
parent 7add08036c
commit ef2b62a852
3 changed files with 1440 additions and 1471 deletions

View File

@ -317,13 +317,10 @@ module.exports = grammar({
at_keyword: $ => /@[a-zA-Z-_]+/,
comment: $ => token(choice(
seq('//', /.*/),
seq(
'/*',
/[^*]*\*+([^/*][^*]*\*+)*/,
'/'
)
comment: $ => token(seq(
'/*',
/[^*]*\*+([^/*][^*]*\*+)*/,
'/'
))
}
})

36
src/grammar.json vendored
View File

@ -1571,37 +1571,19 @@
"comment": {
"type": "TOKEN",
"content": {
"type": "CHOICE",
"type": "SEQ",
"members": [
{
"type": "SEQ",
"members": [
{
"type": "STRING",
"value": "//"
},
{
"type": "PATTERN",
"value": ".*"
}
]
"type": "STRING",
"value": "/*"
},
{
"type": "SEQ",
"members": [
{
"type": "STRING",
"value": "/*"
},
{
"type": "PATTERN",
"value": "[^*]*\\*+([^\\/*][^*]*\\*+)*"
},
{
"type": "STRING",
"value": "/"
}
]
"type": "PATTERN",
"value": "[^*]*\\*+([^\\/*][^*]*\\*+)*"
},
{
"type": "STRING",
"value": "/"
}
]
}

2864
src/parser.c vendored

File diff suppressed because it is too large Load Diff