exec comments added (for shell)

This commit is contained in:
ProgramSnail 2023-07-21 14:11:13 +03:00
parent 567f75620d
commit 39f31b901d
3 changed files with 6 additions and 1 deletions

View file

@ -4,6 +4,7 @@ module.exports = grammar({
word: $ => $.identifier,
extras: $ => [
$._exec_comment,
$._line_comment,
$._block_comment,
/\s/
@ -240,6 +241,7 @@ module.exports = grammar({
definition_info: $ => repeat1(seq(': ', /[^\n]*/)),
annotation_info: $ => seq($.annotation_identifier, /[^\n]*/),
_exec_comment: $ => token(seq('#!', /[^\n]*/)),
_line_comment: $ => token(seq('//', /[^\n]*/)),
_block_comment: $ => token(seq('/*', /([^*]|(\*[^/]))*/, '*/')),