Skip to content

Fix broken codegen, use rustfmt instead - #313

Merged
SimonSapin merged 4 commits into
mainfrom
codegen-fmt
Sep 14, 2026
Merged

SimonSapin merged 4 commits into
mainfrom
codegen-fmt

Conversation

@SimonSapin

Copy link
Copy Markdown
Member

This fixes #311 and fixes #312, building on top of it to add optional use of rustfmt to format generated code. If rustfmt is not available, fall back silently to writing unformatted code.

When rustup is installed but rustfmt is not, `~/.cargo/bin/rustfmt` exists
and prints and error message. `Command::spawn` succeeds, but we need to check
the exist status.

Signed-off-by: Simon Sapin <simon@igalia.com>
Signed-off-by: Simon Sapin <simon@igalia.com>
@SimonSapin
SimonSapin added this pull request to the merge queue Sep 14, 2026
Merged via the queue into main with commit 5f845e2 Sep 14, 2026
4 checks passed
@SimonSapin
SimonSapin deleted the codegen-fmt branch September 14, 2026 16:32
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.

Codegen bug: broken macro

3 participants