Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: handle minus and asterisk marker confidently #1134

Merged
merged 2 commits into from
Jan 9, 2025
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
test: add some tests about assign
  • Loading branch information
Myriad-Dreamin committed Jan 9, 2025
commit 762888ca3d4a2a5c2568225c8857e29ca6819574
3 changes: 3 additions & 0 deletions syntaxes/textmate/tests/unit/basic/assign.typ
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#let (a, b) = (1, 1);
#a = 1
#(a, b) = (b, a)
36 changes: 36 additions & 0 deletions syntaxes/textmate/tests/unit/basic/assign.typ.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
>#let (a, b) = (1, 1);
#^ 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 meta.brace.round.typst
# ^ source.typst meta.expr.let.typst variable.other.readwrite.typst
# ^ source.typst meta.expr.let.typst punctuation.separator.comma.typst
# ^ source.typst meta.expr.let.typst
# ^ source.typst meta.expr.let.typst variable.other.readwrite.typst
# ^ source.typst meta.expr.let.typst meta.brace.round.typst
# ^ source.typst meta.expr.let.typst
# ^^ source.typst meta.expr.let.typst keyword.operator.assignment.typst
# ^ source.typst meta.expr.let.typst meta.brace.round.typst
# ^ source.typst meta.expr.let.typst constant.numeric.integer.typst
# ^ source.typst meta.expr.let.typst punctuation.separator.comma.typst
# ^ source.typst meta.expr.let.typst
# ^ source.typst meta.expr.let.typst constant.numeric.integer.typst
# ^ source.typst meta.expr.let.typst meta.brace.round.typst
# ^ source.typst punctuation.terminator.statement.typst
>#a = 1
#^ source.typst variable.other.readwrite.hash.typst
# ^ source.typst variable.other.readwrite.typst
# ^^^^^ source.typst
>#(a, b) = (b, a)
#^ source.typst keyword.control.hash.typst
# ^ source.typst meta.brace.round.typst
# ^ source.typst variable.other.readwrite.typst
# ^ source.typst punctuation.separator.comma.typst
# ^ source.typst
# ^ source.typst variable.other.readwrite.typst
# ^ source.typst meta.brace.round.typst
# ^^^ source.typst
# ^ source.typst markup.content.brace.typst
# ^^^^ source.typst
# ^ source.typst markup.content.brace.typst
>
Loading