The C variadic spellings ("..." and the GNU "name..."), an empty or
trailing parameter, a missing comma, a stray token and an unterminated
list all parsed silently before: non-identifier tokens were skipped, so
"#define M(...)" defined a zero-parameter macro and invocations were
diagnosed only by argument count, if at all. The toolchain rejects the
definition itself ("bad definition for macro"), and so does the
preprocessor now: the parameter list must be identifiers separated by
single commas and closed by the parenthesis, and a rejected definition
leaves the name unbound. The spellings join the fuzz corpus.
Assisted-by: GLM 5.3
The lexer folds NAME.selector into one identifier, and an object macro
reached through the selector expands with it travelling along, so a
label spelled NAME.selector: restructures exactly like the bare name
would. The macro-name checks now resolve the prefix before the first
period, and the crashing input joins the corpus.
Assisted-by: GLM 5.3
Peeling a stacked label whose name is a macro moves it onto a line of
its own, where its expansion decides the line's shape: an empty body
leaves a bare colon behind, a line the parser rejects. The peel loops
now hold such labels back with the rest of the line, and the crashing
input joins the corpus.
Assisted-by: GLM 5.3
The canonical form splits a label from the instruction that follows it,
but an identifier naming a macro may expand into any token at all: moved
to a line of its own it no longer parses, because the parser accepts a
non-mnemonic first token only behind a label. The names #define'd in
the file now hold such content back, conservatively across the whole
file, and the crashing input joins the corpus.
Assisted-by: GLM 5.3
A label whose name is a macro expands into whatever the body is, so the
line's statement structure exists only after expansion; splitting the
label off changed clean input into a different statement sequence. The
formatter now records the names #define'd above each line and renders
such a label line unsplit, and the crashing input joins the corpus.
Assisted-by: GLM 5.3
An unterminated block comment at the end of a file swallows the
formatter's mandatory final newline, an artifact the token view already
documents as layout; the preproc signature entry now trims it so the
invariant stays about tokens. The triggering input joins the corpus.
Assisted-by: GLM 5.3
A bare GLOBL or DATA parsed without a single diagnostic while leaving a
nil Name in the tree, a pointer every downstream tool dereferences; TEXT
keeps a placeholder beside its error for exactly that reason, and GLOBL
and DATA now do the same. The crashing input enters the corpus.
Assisted-by: GLM 5.3
The two inputs the expansion round-trip target was built for, the object
macro with a parenthesised body and the continuation-only macro body,
enter the seed corpus so every plain go test run replays them.
Assisted-by: GLM 5.3
The one-blank rule before a new block skipped every line that followed a
TEXT directive, not just the function's first label, so a TEXT with an
empty body ran straight into the next declaration. The exemption now
applies to labels only, and the directive shapes around GLOBL and DATA
ranges are pinned.
Assisted-by: GLM 5.3
The include guard's scope is now pinned from three sides: a file
including itself is a cycle diagnostic, a chain of two thousand distinct
headers completes with the deepest content spliced, and a header reached
again through a separate branch splices a second time and is refused as
a redefinition.
Assisted-by: GLM 5.3
Three property tests walk every .s file under the installed GOROOT plus
the repository's kernels: formatting is idempotent and preserves the
token stream, a clean parse keeps its tree through a format pass, and a
cleanly expanding file expands to the same statements afterwards. The
walks skip under -short so the push suite keeps its budget.
Assisted-by: GLM 5.3
A second formatter target holds the assembly path's contract: beyond the
token view, a file the expander reads cleanly must expand to the same
statement sequence after formatting, because the macro language draws
distinctions from layout (the adjacency of a #define name and its '(',
continuation bodies) that a token count cannot see.
Assisted-by: GLM 5.3
The canonical spelling of a #define line glued a '(' to the macro name
whatever the input's spacing, turning an object macro whose body opens
with a parenthesis into a parameterised one, and it flattened the
backslash continuations of a multi-line body into one physical line,
fusing the statements the expansion splits at those boundaries. Both
change what a valid file assembles to, so renderPreproc now keeps the
name's adjacency (the same column check the preprocessor applies) and
restores the continuation boundaries from the token positions.
Assisted-by: GLM 5.3
The RISC-V vector extension and the LoongArch LSX/LASX families carry
no x/arch decode tables, and the loong64 WORD directive is no
instruction: all three stay on the placeholder. The pins record
today's refusal with the corpus rows that assemble the same bytes, so
a decoder bump that learns one of these spaces flips a row here and
asks for the naming pass to cover it.
Assisted-by: GLM 5.3