diff options
| author | Leedehai <18319900+Leedehai@users.noreply.github.com> | 2024-04-02 05:07:00 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-04-02 09:07:00 +0000 |
| commit | c225adb22bb6a445f1cf7f0261e9a937ce397988 (patch) | |
| tree | 6bd75557a78aed5bb2e4022a93273e67936f9cf0 /tests | |
| parent | f461b2059d6733621630f07bc1c9ee039408c9be (diff) | |
Fix tab rendering for raw block with lang "typ(c)" (#3847)
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/ref/bugs/3841-tabs-in-raw-typ-code.png | bin | 0 -> 13011 bytes | |||
| -rw-r--r-- | tests/typ/bugs/3841-tabs-in-raw-typ-code.typ | 20 |
2 files changed, 20 insertions, 0 deletions
diff --git a/tests/ref/bugs/3841-tabs-in-raw-typ-code.png b/tests/ref/bugs/3841-tabs-in-raw-typ-code.png Binary files differnew file mode 100644 index 00000000..37dab136 --- /dev/null +++ b/tests/ref/bugs/3841-tabs-in-raw-typ-code.png diff --git a/tests/typ/bugs/3841-tabs-in-raw-typ-code.typ b/tests/typ/bugs/3841-tabs-in-raw-typ-code.typ new file mode 100644 index 00000000..db04fe3c --- /dev/null +++ b/tests/typ/bugs/3841-tabs-in-raw-typ-code.typ @@ -0,0 +1,20 @@ +// Issue 3841 Tab chars are not rendered in raw blocks with lang: "typ(c)" +// https://github.com/typst/typst/issues/3841 + +#raw("#if true {\n\tf()\t// typ\n}", lang: "typ") + +#raw("if true {\n\tf()\t// typc\n}", lang: "typc") + +```typ +#if true { + // tabs around f() + f() // typ +} +``` + +```typc +if true { + // tabs around f() + f() // typc +} +``` |
