Oregami
Repositories/oxedyne/fe2o3

oxedyne/fe2o3/fe2o3_austenite/tests/oracle/fixtures/let_value_fixture.typ

1.8 KiB, 1 run

created by r1870400018:59176, which is this file's identity for as long as the history lasts, whatever it is later renamed to

download · who wrote it · its history

1// The scalar `#let` value-binding regression root (reader-completeness item 2). `content_bindings.rs`
2// already exercises a `#let name = [ ... ]` content binding and a `#let f(p) = block/box(...)` furniture
3// function unit-level; this is the oracle root proving the third shape -- a bare `#let name = <literal>`
4// scalar (a string, an integer or a length) -- renders through the reader, not just past it. Before the
5// fix, a reference to any of these three names rendered its raw `#name` text (the generic-call fallback
6// has no group to fold in, so it falls through to plain text with the `#` kept); the fix substitutes the
7// literal's own display text instead, in both a heading title and running prose. Deliberately self-contained
8// (a local `#let doc`, plain-text body), so it needs no symbol-modifier patch to compile under typst 0.15.1.
9#let doc(body, heading-font: "Libertinus Serif") = body
10#show: doc.with(heading-font: "Libertinus Serif")
11
12#let title = "Cheap Thinking Field Guide"
13#let version = "1.2"
14#let edition = 3
15
16= #title
17
18This paragraph precedes the reference-bearing ones, written long enough to wrap onto more than one line so
19the page carries real body text the raster sample can land on rather than a single short line where a
20regression might hide.
21
22This is version #version, edition #edition, of the guide. A regression that stopped substituting either
23scalar would print the raw source token instead of its value, moving both the running text and the pinned
24PDF hash.
25
26== #title, Edition #edition
27
28A second heading also references both a string and a numeric scalar, so the fixture exercises substitution
29in a heading title beyond the document's own first one, and carries a second heading for the oracle's
30order-matched anchor-page comparison to line up against.
31
32The edition number repeats here as plain prose: edition #edition, version #version.