diff options
| author | Laurenz <laurmaedje@gmail.com> | 2023-07-24 12:27:24 +0200 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2023-07-24 12:27:24 +0200 |
| commit | c0af6e3569ac7893450d7aae08c6b38de5c976d0 (patch) | |
| tree | 27ea0ac4649ff00eceb770d8af06635b51e25d52 | |
| parent | c23d036426a1bb96620f2d20215a8efe14ef6746 (diff) | |
Fix for loop (with key) autocompletion
The special-case for loop syntax does not exist anymore, but the pattern syntax covers the use case. Fixes #1778.
| -rw-r--r-- | crates/typst/src/ide/complete.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/typst/src/ide/complete.rs b/crates/typst/src/ide/complete.rs index 099454ef..c633731c 100644 --- a/crates/typst/src/ide/complete.rs +++ b/crates/typst/src/ide/complete.rs @@ -849,7 +849,7 @@ fn code_completions(ctx: &mut CompletionContext, hashtag: bool) { ctx.snippet_completion( "for loop (with key)", - "for ${key}, ${value} in ${(a: 1, b: 2)} {\n\t${}\n}", + "for (${key}, ${value}) in ${(a: 1, b: 2)} {\n\t${}\n}", "Computes or inserts something for each key and value in a collection.", ); |
