Don't parse and reserialize toml in configure.py #112445
Labels
C-cleanup
Category: PRs that clean code up or issues documenting cleanup.
E-easy
Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
E-mentor
Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.
T-bootstrap
Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Currently, configure.py has a lot of code dedicated to parsing and serializing toml: https://github.com/rust-lang/rust/blob/6959dd0ee3e8c0c11d3ea54b258dfaf24f148a49/src/bootstrap/configure.py#L382-L509
90% of this is unnecessary: when we get
--set rust.foo
as an argument, we can writerust.foo = true
directly to config.toml, without needing to parse the toml itself. That should make configure.py a lot simpler, and as a side effect it means the hack to append a profile will be valid toml again: #112281 (comment)@rustbot label E-easy E-mentor
The text was updated successfully, but these errors were encountered: