diff --git a/grammars/Ink.YAML-tmLanguage b/grammars/Ink.YAML-tmLanguage index a129bc6..d3b56d8 100644 --- a/grammars/Ink.YAML-tmLanguage +++ b/grammars/Ink.YAML-tmLanguage @@ -605,6 +605,7 @@ repository: - include: '#logic' - include: '#choice' - include: '#glue' + - include: '#todo' - include: '#interpolevaluablock' - include: '#comment' @@ -622,6 +623,7 @@ repository: - include: '#logic' - include: '#choice' - include: '#glue' + - include: '#todo' - include: '#interpolevaluablock' - include: '#comment' diff --git a/grammars/Ink.tmLanguage b/grammars/Ink.tmLanguage index 78f59af..cf8aca4 100644 --- a/grammars/Ink.tmLanguage +++ b/grammars/Ink.tmLanguage @@ -1642,6 +1642,10 @@ include #glue + + include + #todo + include #interpolevaluablock @@ -1701,6 +1705,10 @@ include #glue + + include + #todo + include #interpolevaluablock diff --git a/tests/cases/extra/todo.ink b/tests/cases/extra/todo.ink new file mode 100644 index 0000000..8515595 --- /dev/null +++ b/tests/cases/extra/todo.ink @@ -0,0 +1,82 @@ +// SYNTAX TEST "source.ink" + +TODO: Lorem ipsum +//<---- comment.line.ink entity.todo.ink constant.other entity.todo.begin.ink +// ^^^^^^^^^^^^^ comment.line.ink entity.todo.ink + +=== knot === +//<--- storage.knot.ink punctuation.definition.generic.begin.ink storage.type.ink +// ^ source.ink +// ^^^^ entity.name.function.ink +// ^ source.ink +// ^^^ storage.knot.ink punctuation.definition.generic.end.ink storage.type.ink += stitch +//<- storage.knot.ink punctuation.definition.generic.begin.ink storage.type.ink +//<~- source.ink +//^^^^^^ entity.name.function.ink + { +//<---- source.ink +// ^ keyword.control.ink + - (variable != 4): +//<-------- source.ink +// ^ keyword.control.ink +// ^ source.ink +// ^^^^^^^^^^^^^^^ keyword.control.ink +// ^ keyword.control.ink + TODO: Lorem ipsum +//<------------ comment.line.ink entity.todo.ink +// ^^^^ comment.line.ink entity.todo.ink constant.other entity.todo.begin.ink +// ^^^^^^^^^^^^^ comment.line.ink entity.todo.ink + Text +//<------------ source.ink + } +//<---- source.ink +// ^ keyword.control.ink + + {condition: +//<---- source.ink +// ^ keyword.control.ink +// ^^^^^^^^^^ keyword.control.ink + TODO: Lorem ipsum +//<-------- comment.line.ink entity.todo.ink +// ^^^^ comment.line.ink entity.todo.ink constant.other entity.todo.begin.ink +// ^^^^^^^^^^^^^ comment.line.ink entity.todo.ink + Text +//<-------- source.ink + } +//<---- source.ink +// ^ keyword.control.ink + +TODO: Lorem ipsum +//<---- comment.line.ink entity.todo.ink constant.other entity.todo.begin.ink +// ^^^^^^^^^^^^^ comment.line.ink entity.todo.ink + +* (label) {condition} [Hello] Choice +//<- keyword.choice.ink keyword.operator.arithmetic.ink +//<~- source.ink +//^ string.label.ink entity.name.label.ink string.quoted.other.ink punctuation.definition.string.label.begin.ink punctuation.definition.string.begin.ink +// ^^^^^ string.label.ink entity.name.label.ink string.quoted.other.ink +// ^ string.label.ink entity.name.label.ink string.quoted.other.ink punctuation.definition.string.label.begin.ink punctuation.definition.string.begin.ink +// ^ source.ink +// ^ keyword.control.ink +// ^^^^^^^^^ keyword.control.ink +// ^ keyword.control.ink +// ^ source.ink +// ^ keyword.choice.suppression.ink keyword.control.ink +// ^^^^^ source.ink +// ^ keyword.choice.suppression.ink keyword.control.ink +// ^^^^^^^ source.ink +TODO: Lorem ipsum +//<---- comment.line.ink entity.todo.ink constant.other entity.todo.begin.ink +// ^^^^^^^^^^^^^ comment.line.ink entity.todo.ink +-> the_end +//<-- keyword.divert.ink keyword.other.ink +//^ source.ink +// ^^^^^^^ variable.other.knot.ink entity.name.variable.other.knot.ink + +/* +//<-- comment.block.ink punctuation.definition.comment.ink + TODO: Lorem ipsum +//<--------------------- comment.block.ink +*/ +//<-- comment.block.ink punctuation.definition.comment.ink