-
Notifications
You must be signed in to change notification settings - Fork 360
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cargo miri test
hangs on doc-tests with edition 2024
#4201
Comments
It looks like the behavior of rustdoc that cargo-miri was relying on changed in the 2024 edition. I'm sure it changed for the better, we just need equivalent tweaks to cargo-miri. ...and also we don't test cargo-miri very much 🤦 |
We do test cargo-miri quite a bit but not on edition 2024.^^ Cc @rust-lang/rustdoc in case you have an idea what might have changed here. |
Rustdoc combined tests is the biggest change I remember happening. If |
Skimming the code and running with debug-output it looks like
while in edition=2021 the final line looks like (then it continues to actually compile and run the tests):
(the The biggest difference is using a file vs. stdin for the code, looks like Line 377 in 939ae79
|
Ah yes, we do feed the file to rustdoc via stdin. Hm, will we have to detect the edition to know whether to forward stdin or not? |
Should be able to just check if the final arg is |
We can fairly easily check if an arg of |
cargo miri test
hangs on doc-tests with edition 2024 with cargo 1.87.0-nightly (ce948f461 2025-02-14).Steps to reproduce:
$ cargo init --lib --edition 2024 foo
src/lib.rs
:cargo +nightly miri test
:It hangs on
Doc-tests foo
. If you change the edition to 2021 inCargo.toml
it no longer hangs.The text was updated successfully, but these errors were encountered: