mirror of
https://github.com/Myriad-Dreamin/tinymist.git
synced 2025-12-23 08:47:50 +00:00
fix: better grammar on incomplete AST (#140)
* dev: error tolerance on editing let/show statements * dev: error tolerance on editing if/show statements * dev: error tolerance on editing while/for statements * dev: error tolerance on editing if/while/for statements * dev: better token for and or not
This commit is contained in:
parent
38c54a70da
commit
2e39afde78
51 changed files with 336 additions and 56 deletions
|
|
@ -439,7 +439,7 @@ const expression = (): textmate.Grammar => {
|
|||
},
|
||||
{
|
||||
match: /\b(and|or|not)\b(?!-)/,
|
||||
name: "keyword.operator.logical.typst",
|
||||
name: "keyword.other.logical.typst",
|
||||
},
|
||||
{
|
||||
match: /\b(return)\b(?!-)/,
|
||||
|
|
@ -462,6 +462,7 @@ const expression = (): textmate.Grammar => {
|
|||
{ include: "#primitiveColors" },
|
||||
{ include: "#primitiveFunctions" },
|
||||
{ include: "#primitiveTypes" },
|
||||
// todo: enable if only if for completely right grammar
|
||||
{ include: "#identifier" },
|
||||
{ include: "#constants" },
|
||||
{
|
||||
|
|
@ -817,7 +818,7 @@ const letStatement = (): textmate.Grammar => {
|
|||
const letBindingClause: textmate.Pattern = {
|
||||
// name: "meta.let.binding.typst",
|
||||
begin: /(let\b(?!-))\s*/,
|
||||
end: /(?=[=;\]}])/,
|
||||
end: /(?=[=;\]}\n])/,
|
||||
beginCaptures: {
|
||||
"1": {
|
||||
name: "storage.type.typst",
|
||||
|
|
@ -912,7 +913,7 @@ const ifStatement = (): textmate.Grammar => {
|
|||
const ifStatement: textmate.Pattern = {
|
||||
name: "meta.expr.if.typst",
|
||||
begin: lookAhead(/(else\s+)?(if\b(?!-))/),
|
||||
end: /(?<=\}|\])(?!\s*else\b(?!-))/,
|
||||
end: /(?<=\}|\])(?!\s*else\b(?!-))|(?=[;\}\]\)\n]|$)/,
|
||||
patterns: [
|
||||
/// Matches any comments
|
||||
{
|
||||
|
|
@ -946,7 +947,7 @@ const ifStatement = (): textmate.Grammar => {
|
|||
const ifClause: textmate.Pattern = {
|
||||
// name: "meta.if.clause.typst",
|
||||
begin: /(?:(\belse)\s+)?(\bif)\s+/,
|
||||
end: /(?<!(?:if|and|or|not|in|!=|==|<=|>=|<|>|\+|-|\*|\/|=|\+=|-=|\*=|\/=)\s+)(?=[\[\{])|(?=[;\]}]|$)/,
|
||||
end: /(?<!(?:if|and|or|not|in|!=|==|<=|>=|<|>|\+|-|\*|\/|=|\+=|-=|\*=|\/=)\s*)(?=[\[\{\n])|(?=[;\n\]}]|$)/,
|
||||
beginCaptures: {
|
||||
"1": {
|
||||
name: "keyword.control.conditional.typst",
|
||||
|
|
@ -1028,7 +1029,7 @@ const forStatement = (): textmate.Grammar => {
|
|||
const forStatement: textmate.Pattern = {
|
||||
name: "meta.expr.for.typst",
|
||||
begin: lookAhead(/(for\b(?!-))\s*/),
|
||||
end: /(?<=[\}\]])(?=\s*[\n\S;\}\]\)])(?!\s*[\{\[])/,
|
||||
end: /(?<=[\}\]])(?=\s*[\n\S;\}\]\)])(?!\s*[\{\[])|(?=[;\}\]\)\n]|$)/,
|
||||
patterns: [
|
||||
/// Matches any comments
|
||||
{
|
||||
|
|
@ -1055,7 +1056,7 @@ const forStatement = (): textmate.Grammar => {
|
|||
begin: new RegExp(
|
||||
/(for\b)\s*/.source + `(${BRACE_FREE_EXPR}|${CODE_BLOCK})\\s*(in)\\s*`
|
||||
),
|
||||
end: /(?=[;{\[\}\]\)]|$)/,
|
||||
end: /(?=[;{\[\}\]\)\n]|$)/,
|
||||
beginCaptures: {
|
||||
"1": {
|
||||
name: "keyword.control.loop.typst",
|
||||
|
|
@ -1113,7 +1114,7 @@ const whileStatement = (): textmate.Grammar => {
|
|||
const whileStatement: textmate.Pattern = {
|
||||
name: "meta.expr.while.typst",
|
||||
begin: lookAhead(/(while\b(?!-))/),
|
||||
end: /(?<=\}|\])/,
|
||||
end: /(?<=\}|\])|(?=[;\}\]\)\n]|$)/,
|
||||
patterns: [
|
||||
/// Matches any comments
|
||||
{
|
||||
|
|
@ -1137,7 +1138,7 @@ const whileStatement = (): textmate.Grammar => {
|
|||
const whileClause: textmate.Pattern = {
|
||||
// name: "meta.while.clause.bind.typst",
|
||||
begin: /(while\b)\s*/,
|
||||
end: /(?<!(?:if|and|or|not|in|!=|==|<=|>=|<|>|\+|-|\*|\/|=|\+=|-=|\*=|\/=)\s+)(?=[\[\{])|(?=[;\}\]\)]|$)/,
|
||||
end: /(?<!(?:if|and|or|not|in|!=|==|<=|>=|<|>|\+|-|\*|\/|=|\+=|-=|\*=|\/=)\s+)(?=[\[\{])|(?=[;\}\]\)\n]|$)/,
|
||||
beginCaptures: {
|
||||
"1": {
|
||||
name: "keyword.control.loop.typst",
|
||||
|
|
@ -1290,7 +1291,7 @@ const showStatement = (): textmate.Grammar => {
|
|||
const showSelectClause: textmate.Pattern = {
|
||||
// name: "meta.show.clause.select.typst",
|
||||
begin: /(show\b)\s*/,
|
||||
end: /(?=[:;\}\]])/,
|
||||
end: /(?=[:;\}\]\n])/,
|
||||
beginCaptures: {
|
||||
"1": {
|
||||
name: "keyword.control.other.typst",
|
||||
|
|
|
|||
|
|
@ -1,15 +1,15 @@
|
|||
>#for i
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^^^ source.typst meta.expr.for.typst
|
||||
# ^^^^^ source.typst meta.expr.for.typst
|
||||
>#for i in
|
||||
#^ source.typst meta.expr.for.typst
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^ source.typst meta.expr.for.typst keyword.control.loop.typst
|
||||
# ^ source.typst meta.expr.for.typst
|
||||
# ^ source.typst meta.expr.for.typst variable.other.readwrite.typst
|
||||
# ^ source.typst meta.expr.for.typst
|
||||
# ^^ source.typst meta.expr.for.typst keyword.operator.range.typst
|
||||
>#for i in range(1)
|
||||
#^ source.typst meta.expr.for.typst
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^ source.typst meta.expr.for.typst keyword.control.loop.typst
|
||||
# ^ source.typst meta.expr.for.typst
|
||||
# ^ source.typst meta.expr.for.typst variable.other.readwrite.typst
|
||||
|
|
@ -21,7 +21,7 @@
|
|||
# ^ source.typst meta.expr.for.typst meta.expr.call.typst constant.numeric.integer.typst
|
||||
# ^ source.typst meta.expr.for.typst meta.expr.call.typst meta.brace.round.typst
|
||||
>#for i in range(1) []
|
||||
#^ source.typst meta.expr.for.typst
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^ source.typst meta.expr.for.typst keyword.control.loop.typst
|
||||
# ^ source.typst meta.expr.for.typst
|
||||
# ^ source.typst meta.expr.for.typst variable.other.readwrite.typst
|
||||
|
|
|
|||
|
|
@ -1,15 +1,15 @@
|
|||
>#for i
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^^^ source.typst meta.expr.for.typst
|
||||
# ^^^^^ source.typst meta.expr.for.typst
|
||||
>#for i in
|
||||
#^ source.typst meta.expr.for.typst
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^ source.typst meta.expr.for.typst keyword.control.loop.typst
|
||||
# ^ source.typst meta.expr.for.typst
|
||||
# ^ source.typst meta.expr.for.typst variable.other.readwrite.typst
|
||||
# ^ source.typst meta.expr.for.typst
|
||||
# ^^ source.typst meta.expr.for.typst keyword.operator.range.typst
|
||||
>#for i in range(1)
|
||||
#^ source.typst meta.expr.for.typst
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^ source.typst meta.expr.for.typst keyword.control.loop.typst
|
||||
# ^ source.typst meta.expr.for.typst
|
||||
# ^ source.typst meta.expr.for.typst variable.other.readwrite.typst
|
||||
|
|
@ -21,7 +21,7 @@
|
|||
# ^ source.typst meta.expr.for.typst meta.expr.call.typst constant.numeric.integer.typst
|
||||
# ^ source.typst meta.expr.for.typst meta.expr.call.typst meta.brace.round.typst
|
||||
>#for i in range(1) {}
|
||||
#^ source.typst meta.expr.for.typst
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^ source.typst meta.expr.for.typst keyword.control.loop.typst
|
||||
# ^ source.typst meta.expr.for.typst
|
||||
# ^ source.typst meta.expr.for.typst variable.other.readwrite.typst
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst constant.numeric.integer.typst
|
||||
>#if [] 1
|
||||
#^ source.typst meta.expr.if.typst
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
|
|
@ -12,7 +12,7 @@
|
|||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst constant.numeric.integer.typst
|
||||
>#if [] else [] 1
|
||||
#^ source.typst meta.expr.if.typst
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst constant.numeric.integer.typst
|
||||
>#if {} 1
|
||||
#^ source.typst meta.expr.if.typst
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
|
|
@ -12,7 +12,7 @@
|
|||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst constant.numeric.integer.typst
|
||||
>#if {} else {} 1
|
||||
#^ source.typst meta.expr.if.typst
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
|
|
@ -594,7 +594,7 @@
|
|||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
|
|
@ -611,7 +611,7 @@
|
|||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
|
|
@ -626,7 +626,7 @@
|
|||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
|
|
@ -641,7 +641,7 @@
|
|||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
|
|
@ -658,7 +658,7 @@
|
|||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
|
|
@ -673,7 +673,7 @@
|
|||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
|
|
@ -688,7 +688,7 @@
|
|||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
|
|
@ -705,7 +705,7 @@
|
|||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
|
|
@ -720,7 +720,7 @@
|
|||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
|
|
@ -733,7 +733,7 @@
|
|||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
|
|
@ -747,7 +747,7 @@
|
|||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
|
|
@ -759,7 +759,7 @@
|
|||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
|
|
@ -771,7 +771,7 @@
|
|||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
|
|
@ -785,7 +785,7 @@
|
|||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
|
|
@ -797,7 +797,7 @@
|
|||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.square.typst
|
||||
|
|
@ -809,7 +809,7 @@
|
|||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
|
|
@ -823,7 +823,7 @@
|
|||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
|
|
@ -835,7 +835,7 @@
|
|||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
|
|
|
|||
|
|
@ -2,12 +2,12 @@
|
|||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^^ source.typst meta.expr.while.typst keyword.control.loop.typst
|
||||
>#while i
|
||||
#^ source.typst meta.expr.while.typst
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^^ source.typst meta.expr.while.typst keyword.control.loop.typst
|
||||
# ^ source.typst meta.expr.while.typst
|
||||
# ^ source.typst meta.expr.while.typst variable.other.readwrite.typst
|
||||
>#while i {}
|
||||
#^ source.typst meta.expr.while.typst
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^^ source.typst meta.expr.while.typst keyword.control.loop.typst
|
||||
# ^ source.typst meta.expr.while.typst
|
||||
# ^ source.typst meta.expr.while.typst variable.other.readwrite.typst
|
||||
|
|
|
|||
3
syntaxes/textmate/tests/unit/editing/for.typ
Normal file
3
syntaxes/textmate/tests/unit/editing/for.typ
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
#for
|
||||
|
||||
test
|
||||
6
syntaxes/textmate/tests/unit/editing/for.typ.snap
Normal file
6
syntaxes/textmate/tests/unit/editing/for.typ.snap
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
>#for
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^ source.typst meta.expr.for.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
3
syntaxes/textmate/tests/unit/editing/for2.typ
Normal file
3
syntaxes/textmate/tests/unit/editing/for2.typ
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
#for i
|
||||
|
||||
test
|
||||
6
syntaxes/textmate/tests/unit/editing/for2.typ.snap
Normal file
6
syntaxes/textmate/tests/unit/editing/for2.typ.snap
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
>#for i
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^^ source.typst meta.expr.for.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
3
syntaxes/textmate/tests/unit/editing/for3.typ
Normal file
3
syntaxes/textmate/tests/unit/editing/for3.typ
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
#for i in
|
||||
|
||||
test
|
||||
11
syntaxes/textmate/tests/unit/editing/for3.typ.snap
Normal file
11
syntaxes/textmate/tests/unit/editing/for3.typ.snap
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
>#for i in
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^ source.typst meta.expr.for.typst keyword.control.loop.typst
|
||||
# ^ source.typst meta.expr.for.typst
|
||||
# ^ source.typst meta.expr.for.typst variable.other.readwrite.typst
|
||||
# ^ source.typst meta.expr.for.typst
|
||||
# ^^ source.typst meta.expr.for.typst keyword.operator.range.typst
|
||||
# ^^ source.typst meta.expr.for.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
3
syntaxes/textmate/tests/unit/editing/for4.typ
Normal file
3
syntaxes/textmate/tests/unit/editing/for4.typ
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
#for i in ()
|
||||
|
||||
test
|
||||
13
syntaxes/textmate/tests/unit/editing/for4.typ.snap
Normal file
13
syntaxes/textmate/tests/unit/editing/for4.typ.snap
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
>#for i in ()
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^ source.typst meta.expr.for.typst keyword.control.loop.typst
|
||||
# ^ source.typst meta.expr.for.typst
|
||||
# ^ source.typst meta.expr.for.typst variable.other.readwrite.typst
|
||||
# ^ source.typst meta.expr.for.typst
|
||||
# ^^ source.typst meta.expr.for.typst keyword.operator.range.typst
|
||||
# ^ source.typst meta.expr.for.typst
|
||||
# ^ source.typst meta.expr.for.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.for.typst meta.brace.round.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
3
syntaxes/textmate/tests/unit/editing/for5.typ
Normal file
3
syntaxes/textmate/tests/unit/editing/for5.typ
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
#{for}
|
||||
|
||||
test
|
||||
8
syntaxes/textmate/tests/unit/editing/for5.typ.snap
Normal file
8
syntaxes/textmate/tests/unit/editing/for5.typ.snap
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
>#{for}
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^ source.typst meta.brace.curly.typst
|
||||
# ^^^ source.typst meta.expr.for.typst
|
||||
# ^ source.typst meta.brace.curly.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
4
syntaxes/textmate/tests/unit/editing/if.typ
Normal file
4
syntaxes/textmate/tests/unit/editing/if.typ
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
|
||||
#if
|
||||
|
||||
test #a
|
||||
10
syntaxes/textmate/tests/unit/editing/if.typ.snap
Normal file
10
syntaxes/textmate/tests/unit/editing/if.typ.snap
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
>
|
||||
>#if
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
>
|
||||
>test #a
|
||||
#^^^^^ source.typst
|
||||
# ^ source.typst variable.other.readwrite.hash.typst
|
||||
# ^ source.typst variable.other.readwrite.typst
|
||||
>
|
||||
4
syntaxes/textmate/tests/unit/editing/if2.typ
Normal file
4
syntaxes/textmate/tests/unit/editing/if2.typ
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
|
||||
#if a
|
||||
|
||||
test #a
|
||||
12
syntaxes/textmate/tests/unit/editing/if2.typ.snap
Normal file
12
syntaxes/textmate/tests/unit/editing/if2.typ.snap
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
>
|
||||
>#if a
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst variable.other.readwrite.typst
|
||||
>
|
||||
>test #a
|
||||
#^^^^^ source.typst
|
||||
# ^ source.typst variable.other.readwrite.hash.typst
|
||||
# ^ source.typst variable.other.readwrite.typst
|
||||
>
|
||||
3
syntaxes/textmate/tests/unit/editing/if3.typ
Normal file
3
syntaxes/textmate/tests/unit/editing/if3.typ
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
#{if}
|
||||
|
||||
test
|
||||
8
syntaxes/textmate/tests/unit/editing/if3.typ.snap
Normal file
8
syntaxes/textmate/tests/unit/editing/if3.typ.snap
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
>#{if}
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^ source.typst meta.brace.curly.typst
|
||||
# ^^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.brace.curly.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
3
syntaxes/textmate/tests/unit/editing/if4.typ
Normal file
3
syntaxes/textmate/tests/unit/editing/if4.typ
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
#{if () {} else}
|
||||
|
||||
test
|
||||
15
syntaxes/textmate/tests/unit/editing/if4.typ.snap
Normal file
15
syntaxes/textmate/tests/unit/editing/if4.typ.snap
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
>#{if () {} else}
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^ source.typst meta.brace.curly.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^ source.typst meta.expr.if.typst meta.brace.curly.typst
|
||||
# ^^^^^ source.typst meta.expr.if.typst
|
||||
# ^ source.typst meta.brace.curly.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
4
syntaxes/textmate/tests/unit/editing/let.typ
Normal file
4
syntaxes/textmate/tests/unit/editing/let.typ
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
|
||||
#let f()
|
||||
|
||||
test
|
||||
12
syntaxes/textmate/tests/unit/editing/let.typ.snap
Normal file
12
syntaxes/textmate/tests/unit/editing/let.typ.snap
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
>
|
||||
>#let f()
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^ source.typst meta.expr.let.typst storage.type.typst
|
||||
# ^ source.typst meta.expr.let.typst
|
||||
# ^ source.typst meta.expr.let.typst entity.name.function.typst
|
||||
# ^ source.typst meta.expr.let.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.let.typst meta.brace.round.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
>
|
||||
4
syntaxes/textmate/tests/unit/editing/let2.typ
Normal file
4
syntaxes/textmate/tests/unit/editing/let2.typ
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
|
||||
#let
|
||||
|
||||
test
|
||||
8
syntaxes/textmate/tests/unit/editing/let2.typ.snap
Normal file
8
syntaxes/textmate/tests/unit/editing/let2.typ.snap
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
>
|
||||
>#let
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^ source.typst meta.expr.let.typst storage.type.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
>
|
||||
4
syntaxes/textmate/tests/unit/editing/let3.typ
Normal file
4
syntaxes/textmate/tests/unit/editing/let3.typ
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
|
||||
#let f
|
||||
|
||||
test
|
||||
10
syntaxes/textmate/tests/unit/editing/let3.typ.snap
Normal file
10
syntaxes/textmate/tests/unit/editing/let3.typ.snap
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
>
|
||||
>#let f
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^ source.typst meta.expr.let.typst storage.type.typst
|
||||
# ^ source.typst meta.expr.let.typst
|
||||
# ^ source.typst meta.expr.let.typst variable.other.readwrite.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
>
|
||||
4
syntaxes/textmate/tests/unit/editing/show.typ
Normal file
4
syntaxes/textmate/tests/unit/editing/show.typ
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
|
||||
#show
|
||||
|
||||
test
|
||||
8
syntaxes/textmate/tests/unit/editing/show.typ.snap
Normal file
8
syntaxes/textmate/tests/unit/editing/show.typ.snap
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
>
|
||||
>#show
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^ source.typst meta.expr.show.typst keyword.control.other.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
>
|
||||
4
syntaxes/textmate/tests/unit/editing/show2.typ
Normal file
4
syntaxes/textmate/tests/unit/editing/show2.typ
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
|
||||
#show:
|
||||
|
||||
test
|
||||
9
syntaxes/textmate/tests/unit/editing/show2.typ.snap
Normal file
9
syntaxes/textmate/tests/unit/editing/show2.typ.snap
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
>
|
||||
>#show:
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^ source.typst meta.expr.show.typst keyword.control.other.typst
|
||||
# ^ source.typst meta.expr.show.typst punctuation.separator.colon.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
>
|
||||
4
syntaxes/textmate/tests/unit/editing/show3.typ
Normal file
4
syntaxes/textmate/tests/unit/editing/show3.typ
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
|
||||
#show text
|
||||
|
||||
test
|
||||
10
syntaxes/textmate/tests/unit/editing/show3.typ.snap
Normal file
10
syntaxes/textmate/tests/unit/editing/show3.typ.snap
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
>
|
||||
>#show text
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^ source.typst meta.expr.show.typst keyword.control.other.typst
|
||||
# ^ source.typst meta.expr.show.typst
|
||||
# ^^^^ source.typst meta.expr.show.typst variable.other.readwrite.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
>
|
||||
4
syntaxes/textmate/tests/unit/editing/show4.typ
Normal file
4
syntaxes/textmate/tests/unit/editing/show4.typ
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
|
||||
#show text.
|
||||
|
||||
test
|
||||
11
syntaxes/textmate/tests/unit/editing/show4.typ.snap
Normal file
11
syntaxes/textmate/tests/unit/editing/show4.typ.snap
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
>
|
||||
>#show text.
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^ source.typst meta.expr.show.typst keyword.control.other.typst
|
||||
# ^ source.typst meta.expr.show.typst
|
||||
# ^^^^ source.typst meta.expr.show.typst variable.other.readwrite.typst
|
||||
# ^ source.typst meta.expr.show.typst keyword.operator.accessor.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
>
|
||||
4
syntaxes/textmate/tests/unit/editing/show5.typ
Normal file
4
syntaxes/textmate/tests/unit/editing/show5.typ
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
|
||||
#show text.where
|
||||
|
||||
test
|
||||
12
syntaxes/textmate/tests/unit/editing/show5.typ.snap
Normal file
12
syntaxes/textmate/tests/unit/editing/show5.typ.snap
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
>
|
||||
>#show text.where
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^ source.typst meta.expr.show.typst keyword.control.other.typst
|
||||
# ^ source.typst meta.expr.show.typst
|
||||
# ^^^^ source.typst meta.expr.show.typst variable.other.readwrite.typst
|
||||
# ^ source.typst meta.expr.show.typst keyword.operator.accessor.typst
|
||||
# ^^^^^ source.typst meta.expr.show.typst variable.other.readwrite.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
>
|
||||
4
syntaxes/textmate/tests/unit/editing/show6.typ
Normal file
4
syntaxes/textmate/tests/unit/editing/show6.typ
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
|
||||
#show text.where()
|
||||
|
||||
test
|
||||
14
syntaxes/textmate/tests/unit/editing/show6.typ.snap
Normal file
14
syntaxes/textmate/tests/unit/editing/show6.typ.snap
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
>
|
||||
>#show text.where()
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^ source.typst meta.expr.show.typst keyword.control.other.typst
|
||||
# ^ source.typst meta.expr.show.typst
|
||||
# ^^^^ source.typst meta.expr.show.typst variable.other.readwrite.typst
|
||||
# ^ source.typst meta.expr.show.typst meta.expr.call.typst keyword.operator.accessor.typst
|
||||
# ^^^^^ source.typst meta.expr.show.typst meta.expr.call.typst entity.name.function.typst
|
||||
# ^ source.typst meta.expr.show.typst meta.expr.call.typst meta.brace.round.typst
|
||||
# ^ source.typst meta.expr.show.typst meta.expr.call.typst meta.brace.round.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
>
|
||||
3
syntaxes/textmate/tests/unit/editing/while.typ
Normal file
3
syntaxes/textmate/tests/unit/editing/while.typ
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
#while
|
||||
|
||||
test
|
||||
6
syntaxes/textmate/tests/unit/editing/while.typ.snap
Normal file
6
syntaxes/textmate/tests/unit/editing/while.typ.snap
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
>#while
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^^ source.typst meta.expr.while.typst keyword.control.loop.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
3
syntaxes/textmate/tests/unit/editing/while2.typ
Normal file
3
syntaxes/textmate/tests/unit/editing/while2.typ
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
#while i
|
||||
|
||||
test
|
||||
8
syntaxes/textmate/tests/unit/editing/while2.typ.snap
Normal file
8
syntaxes/textmate/tests/unit/editing/while2.typ.snap
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
>#while i
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^^^ source.typst meta.expr.while.typst keyword.control.loop.typst
|
||||
# ^ source.typst meta.expr.while.typst
|
||||
# ^ source.typst meta.expr.while.typst variable.other.readwrite.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
3
syntaxes/textmate/tests/unit/editing/while3.typ
Normal file
3
syntaxes/textmate/tests/unit/editing/while3.typ
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
#{while}
|
||||
|
||||
test
|
||||
8
syntaxes/textmate/tests/unit/editing/while3.typ.snap
Normal file
8
syntaxes/textmate/tests/unit/editing/while3.typ.snap
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
>#{while}
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^ source.typst meta.brace.curly.typst
|
||||
# ^^^^^ source.typst meta.expr.while.typst keyword.control.loop.typst
|
||||
# ^ source.typst meta.brace.curly.typst
|
||||
>
|
||||
>test
|
||||
#^^^^^ source.typst
|
||||
|
|
@ -4,7 +4,7 @@
|
|||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^^^ source.typst meta.expr.if.typst entity.name.type.primitive.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^^ source.typst meta.expr.if.typst entity.name.type.primitive.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
|
|
@ -14,7 +14,7 @@
|
|||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^^^ source.typst meta.expr.if.typst entity.name.type.primitive.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
|
|
@ -42,7 +42,7 @@
|
|||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^^^ source.typst meta.expr.if.typst entity.name.type.primitive.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^^ source.typst meta.expr.if.typst entity.name.type.primitive.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
|
|
@ -55,7 +55,7 @@
|
|||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^^^ source.typst meta.expr.if.typst entity.name.type.primitive.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^^ source.typst meta.expr.if.typst entity.name.type.primitive.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
|
|
@ -65,7 +65,7 @@
|
|||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^^^ source.typst meta.expr.if.typst entity.name.type.primitive.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
|
|
@ -76,7 +76,7 @@
|
|||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^ source.typst meta.expr.if.typst keyword.control.conditional.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.if.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
# ^^^^ source.typst meta.expr.if.typst entity.name.type.primitive.typst
|
||||
# ^ source.typst meta.expr.if.typst
|
||||
|
|
@ -121,7 +121,7 @@
|
|||
# ^ source.typst meta.expr.while.typst
|
||||
# ^^^^^ source.typst meta.expr.while.typst entity.name.type.primitive.typst
|
||||
# ^ source.typst meta.expr.while.typst
|
||||
# ^^^ source.typst meta.expr.while.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.while.typst keyword.other.logical.typst
|
||||
# ^ source.typst meta.expr.while.typst
|
||||
# ^^^^ source.typst meta.expr.while.typst entity.name.type.primitive.typst
|
||||
# ^ source.typst meta.expr.while.typst
|
||||
|
|
@ -157,7 +157,7 @@
|
|||
# ^ source.typst meta.expr.set.typst
|
||||
# ^^^^^ source.typst meta.expr.set.typst entity.name.type.primitive.typst
|
||||
# ^^^ source.typst meta.expr.set.typst
|
||||
# ^^^ source.typst meta.expr.set.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.set.typst keyword.other.logical.typst
|
||||
# ^^^^ source.typst meta.expr.set.typst
|
||||
# ^^^^ source.typst meta.expr.set.typst entity.name.type.primitive.typst
|
||||
>#set text(red) if not true
|
||||
|
|
@ -171,7 +171,7 @@
|
|||
# ^ source.typst meta.expr.set.typst
|
||||
# ^^ source.typst meta.expr.set.typst keyword.control.conditional.typst
|
||||
# ^^^ source.typst meta.expr.set.typst
|
||||
# ^^^ source.typst meta.expr.set.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst meta.expr.set.typst keyword.other.logical.typst
|
||||
# ^^^^^^^^^^ source.typst meta.expr.set.typst
|
||||
# ^^^^ source.typst meta.expr.set.typst entity.name.type.primitive.typst
|
||||
>
|
||||
|
|
@ -5,7 +5,7 @@
|
|||
#^^ source.typst
|
||||
# ^^^^^ source.typst entity.name.type.primitive.typst
|
||||
# ^^^^^^^^^^^^^^^^^^^ source.typst
|
||||
# ^^^ source.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst keyword.other.logical.typst
|
||||
# ^^^^^^^^^^^ source.typst
|
||||
# ^^^^ source.typst entity.name.type.primitive.typst
|
||||
# ^ source.typst punctuation.separator.colon.typst
|
||||
|
|
@ -68,7 +68,7 @@
|
|||
# ^^^^^ source.typst meta.expr.set.typst entity.name.type.primitive.typst
|
||||
> and true
|
||||
#^^ source.typst
|
||||
# ^^^ source.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst keyword.other.logical.typst
|
||||
# ^ source.typst
|
||||
# ^^^^ source.typst entity.name.type.primitive.typst
|
||||
>}
|
||||
|
|
|
|||
|
|
@ -54,12 +54,12 @@
|
|||
# ^ source.typst meta.brace.round.typst
|
||||
>#not a
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^^^ source.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst keyword.other.logical.typst
|
||||
# ^^^ source.typst
|
||||
>#(not a)
|
||||
#^ source.typst keyword.control.hash.typst
|
||||
# ^ source.typst meta.brace.round.typst
|
||||
# ^^^ source.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst keyword.other.logical.typst
|
||||
# ^ source.typst
|
||||
# ^ source.typst variable.other.readwrite.typst
|
||||
# ^ source.typst meta.brace.round.typst
|
||||
|
|
@ -68,7 +68,7 @@
|
|||
# ^ source.typst meta.brace.round.typst
|
||||
# ^ source.typst variable.other.readwrite.typst
|
||||
# ^ source.typst
|
||||
# ^^^ source.typst keyword.operator.logical.typst
|
||||
# ^^^ source.typst keyword.other.logical.typst
|
||||
# ^ source.typst
|
||||
# ^^^ source.typst support.type.builtin.typst
|
||||
# ^ source.typst meta.brace.round.typst
|
||||
|
|
@ -77,7 +77,7 @@
|
|||
# ^ source.typst meta.brace.round.typst
|
||||
# ^ source.typst variable.other.readwrite.typst
|
||||
# ^ source.typst
|
||||
# ^^ source.typst keyword.operator.logical.typst
|
||||
# ^^ source.typst keyword.other.logical.typst
|
||||
# ^ source.typst
|
||||
# ^^^ source.typst support.type.builtin.typst
|
||||
# ^ source.typst meta.brace.round.typst
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue