Today I learnt that `cargo fix` won't fix code with compiler errors by default, but you can override this! $ cargo fix --broken-code --allow-dirty && cargo clippy --fix --allow-dirty This incantation does exactly what I wanted :)