Skip to content

Conversation

@RalfJung
Copy link
Member

For Miri I verified this works. For clippy, unfortunately it doesn't seem to work as a stage 0 tool:

./x.py --stage 0 test src/tools/clippy --test-args init

gives

   Compiling clippy-mini-macro-test v0.2.0 (/home/r/src/rust/rustc.3/src/tools/clippy/mini-macro)
error[E0658]: procedural macros cannot be expanded to expressions
  --> src/tools/clippy/mini-macro/src/lib.rs:11:5
   |
11 | /     quote!(
12 | |         #[allow(unused)]
13 | |         fn needless_take_by_value(s: String) {
14 | |             println!("{}", s.len());
...  |
24 | |         }
25 | |     )
   | |_____^
   |
   = note: see issue #54727 <https://github.com/rust-lang/rust/issues/54727> for more information
   = help: add `#![feature(proc_macro_hygiene)]` to the crate attributes to enable

   Compiling proc-macro2 v1.0.3
   Compiling syn v1.0.11
error: aborting due to previous error

For more information about this error, try `rustc --explain E0658`.
error: could not compile `clippy-mini-macro-test`.

But propagating --test-args to the test suite seems to make sense regardless.
Cc @rust-lang/clippy

@rust-highfive
Copy link
Contributor

r? @Mark-Simulacrum

(rust_highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label May 24, 2020
@RalfJung
Copy link
Member Author

I verified that ./x.py test src/tools/clippy --test-args in works as expected.

@Mark-Simulacrum
Copy link
Member

r=me

If you have some time, any chance you can quickly try and check the other test steps are doing this? If not I'd appreciate an issue. Thanks!

@RalfJung
Copy link
Member Author

Opened an issue: #72536

@bors r=Mark-Simulacrum

@bors
Copy link
Collaborator

bors commented May 24, 2020

📌 Commit 7a121ad has been approved by Mark-Simulacrum

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 24, 2020
@RalfJung
Copy link
Member Author

@bors rollup

bors added a commit to rust-lang-ci/rust that referenced this pull request May 24, 2020
Rollup of 5 pull requests

Successful merges:

 - rust-lang#72402 (Remove all uses of `NodeId` in `ResolverOutputs`)
 - rust-lang#72527 (bootstrap: propagate test-args to miri and clippy test suites)
 - rust-lang#72530 (Clean up E0602 explanation)
 - rust-lang#72532 (Use `dyn` trait syntax in more comments and docs)
 - rust-lang#72535 (Use sort_unstable_by in its own docs)

Failed merges:

r? @ghost
@bors bors merged commit a75068a into rust-lang:master May 24, 2020
@RalfJung RalfJung deleted the miri-clippy-test-args branch May 25, 2020 07:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants