Skip to content

Build the paper from the generated wording, and check it against the headers - #105

Merged
steve-downey merged 4 commits into
bemanproject:mainfrom
steve-downey:paper-build-without-specgen
Oct 19, 2026
Merged

steve-downey merged 4 commits into
bemanproject:mainfrom
steve-downey:paper-build-without-specgen

Conversation

@steve-downey

@steve-downey steve-downey commented Oct 19, 2026 •

Copy link
Copy Markdown
Member

Stacked on #104: this branch contains its two commits, so review from "Makefile improvement for paper" onward.

Changes to the paper and how it's built.

  • The clean wording comes from the generated fragments. papers/Makefile now assembles expected-clean.tex, the text for a working-draft pull request, from the specgen-generated wording/expected.tex. Only the hand-written [expected.general] and [expected.syn] come from expected-new.tex, with their change markup stripped. A build started from papers/ delegates to the root makefile first, so the clean wording can't fall behind the headers.
  • The paper builds without specgen. Without specgen on PATH, make papers now warns and uses the checked-in fragments.
  • New make wording-check target. It regenerates the wording into a scratch directory and fails if the checked-in wording has drifted from the headers. It and the real rule share the specgen invocation and the assembly.
  • The checked-in wording is regenerated with specgen 0.4.0, so the new check passes from the start. Ignoring whitespace, there are two changes. Each synopsis is wrapped in namespace std { ... }, as in the working draft, which reindents every synopsis line. And the expected<void, E> destructor pair is now merged into the single constexpr ~expected(); the draft has, with its Effects and triviality Remarks.
  • D4280 prose. Tightened, and limited to C++29: the material that only served the reference implementation or a pre-C++29 language floor is gone. The dangling \nameref{chap:impl} is fixed, and there's a new [version.syn] edit bumping __cpp_lib_expected and __cpp_lib_freestanding_expected, following P2988's treatment of optional.

steve-downey and others added 4 commits October 18, 2026 15:48
Remove the cost/buy metaphors and other stock phrasing, and trim
"not X, but Y" tails and repeated "idiom"/"precisely".

Drop everything that only served the reference implementation or a
pre-C++29 language floor: D10 no longer describes staying at C++20
behind a deleted-function-message fallback, the Beman-only detection
macro section (old D11) is gone, and the implementation notes at the
end of D12 are removed. Remaining decisions are renumbered D11 and D12.

Fix the dangling \nameref{chap:impl}, and add the [version.syn] edit
bumping __cpp_lib_expected and __cpp_lib_freestanding_expected,
following P2988's treatment of optional.
…aders

`make papers` already regenerated the [expected] wording through
specgen's depfile before building the paper. Without specgen on PATH it
now warns and uses the checked-in fragments as they are, so the paper
still builds anywhere; the fragments are not touched, so the warning
repeats until specgen regenerates them.

`make wording-check` regenerates into a scratch directory and compares
the assembled expected.tex and each checked-in fragment, failing if the
checked-in wording has drifted from the headers. The specgen invocation
and the assembly are now shared definitions, so the check and the real
rule cannot drift apart.

The papers target also assembles expected-clean.tex, the clean wording
for a working-draft pull request.
specgen now wraps each synopsis in `namespace std { ... }`, as the working
draft does, which reindents every synopsis line. It also honors the `\merge`
on the expected<void, E> destructor pair: the synopsis shows the single
`constexpr ~expected();` and the itemdescr drops the Constraints paragraph,
leaving the Effects and the triviality Remarks, matching the draft. Ignoring
whitespace, those are the only changes.

`make wording-check` passes against the regenerated files.
@steve-downey
steve-downey merged commit 6ad0e73 into bemanproject:main Oct 19, 2026
78 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant