pattern_type: make print format match the current syntax - #161707
Conversation
|
r? @mati865 rustbot has assigned @mati865. Use Why was this reviewer chosen?The reviewer was selected based on:
|
This comment has been minimized.
This comment has been minimized.
3905879 to
2cbcaa6
Compare
|
r? @mejrs |
This comment has been minimized.
This comment has been minimized.
2cbcaa6 to
4143d96
Compare
4143d96 to
cace07d
Compare
This comment has been minimized.
This comment has been minimized.
cace07d to
2a6be21
Compare
This comment has been minimized.
This comment has been minimized.
2a6be21 to
035eea7
Compare
This comment has been minimized.
This comment has been minimized.
f958f7d to
d812ce0
Compare
This comment has been minimized.
This comment has been minimized.
d812ce0 to
58f5ecf
Compare
|
cc @rust-lang/miri |
|
I did not expect that there would be so many tests expecting this format 😅 Also, I don't think I can split the miri part, because then the tests will fail, in both PRs. |
Those |
…uwer Rollup of 7 pull requests Successful merges: - #161433 (Overhaul `rustc_middle::query`) - #158370 (rewrite never type documentation) - #160354 (update `ambiguous_glob_imported_trait` lint explanation and example.) - #161447 (Construct paramenvs from an iterator) - #161707 (pattern_type: make print format match the current syntax) - #161773 (Update WASI targets to wasi-sdk-34) - #161807 (bootstrap: skip StdarchVerify when remote testing is enabled)
Rollup merge of #161707 - GTimothy:pattern_type-pretty-print-impl, r=mejrs pattern_type: make print format match the current syntax Print a pattern type using the `pattern_type!(type is pattern)` syntax instead of `(type) is pattern`. This helps for example when suggesting fixes: `(type) is pattern` is not valid rust right now but `pattern_type!(type is pattern)` is. This is not a bug as `pattern_type` is not on stable but it is a fairly impact-less change, just a print change. discussion: [#t-compiler > pattern_type pretty format](https://rust-lang.zulipchat.com/#narrow/channel/131828-t-compiler/topic/pattern_type.20pretty.20format/with/618658793) closes rust-lang/rust-clippy#17613
…uwer Rollup of 7 pull requests Successful merges: - rust-lang/rust#161433 (Overhaul `rustc_middle::query`) - rust-lang/rust#158370 (rewrite never type documentation) - rust-lang/rust#160354 (update `ambiguous_glob_imported_trait` lint explanation and example.) - rust-lang/rust#161447 (Construct paramenvs from an iterator) - rust-lang/rust#161707 (pattern_type: make print format match the current syntax) - rust-lang/rust#161773 (Update WASI targets to wasi-sdk-34) - rust-lang/rust#161807 (bootstrap: skip StdarchVerify when remote testing is enabled)
…uwer Rollup of 7 pull requests Successful merges: - rust-lang/rust#161433 (Overhaul `rustc_middle::query`) - rust-lang/rust#158370 (rewrite never type documentation) - rust-lang/rust#160354 (update `ambiguous_glob_imported_trait` lint explanation and example.) - rust-lang/rust#161447 (Construct paramenvs from an iterator) - rust-lang/rust#161707 (pattern_type: make print format match the current syntax) - rust-lang/rust#161773 (Update WASI targets to wasi-sdk-34) - rust-lang/rust#161807 (bootstrap: skip StdarchVerify when remote testing is enabled)
Print a pattern type using the
pattern_type!(type is pattern)syntax instead of(type) is pattern.This helps for example when suggesting fixes:
(type) is patternis not valid rust right now butpattern_type!(type is pattern)is.This is not a bug as
pattern_typeis not on stable but it is a fairly impact-less change, just a print change.discussion: #t-compiler > pattern_type pretty format
closes rust-lang/rust-clippy#17613