Annotation for code blocks that aren't expected to compile
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 36
- Forks
- 9
- Avg merge
- 1h 46m
- Merged PRs (30d)
- 1
Description
Currently packages often use the typ language for readme examples that aren't valid typst code, or don't compile successfully, e.g.
```typ
#let my-func(
a: int,
b: str,
) = { ... }
```
This is a proposal to explicitly annotate these examples with some sort of tag, for example ignore, no-run, should-fail, or even more complex expressions such asexpect-failure=syntax, error=eval, to indicate they won't compile:
```typ ignore
#let my-func(
a: int,
b: str,
) = { ... }
```
This will even leave syntax highlighting intact:
#let my-func(
a: int,
b: str,
) = { ... }
The purpose of adding these tags, is to allow treating all other typ code blocks as tests that should compile.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Begin by locating the code that identifies and checks Typst code blocks; the issue names no file or test to start from. Define the accepted annotation semantics, then verify that tagged blocks are exempt while untagged typ blocks remain compile checks.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- testing, tooling
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100