Re-add double underscores in derive (fixes#32292)
@durka, sanity-check, please?
<s>Don't merge this yet, I need to add a test and test it locally.</s>
ready for review
Stop ignoring expected note/help messages in compiletest suite.
Original issue: https://github.com/rust-lang/rust/issues/21195
Relevant PR: https://github.com/rust-lang/rust/pull/30778
Prior to this commit, if a compiletest testcase included the text
"HELP:" or "NOTE:" (note the colons), then it would indicate to the
compiletest suite that we should verify "help" and "note" expected
messages.
This commit updates this check to also check "HELP" and "NOTE" (not the
absense of colons) so that we always verify "help" and "note" expected
messages.
rustbuild: Implement `make dist`
This commit implements the `make dist` command in the new rustbuild build
system, porting over `dist.mk` and `prepare.mk` into Rust. There's a huge amount
of complexity between those two files, not all of which is likely justified, so
the Rust implementation is *much* smaller.
Currently the implementation still shells out to rust-installer as well as some
python scripts, but ideally we'd rewrite it all in the future to not shell out
and be in Rust proper.
Original issue: https://github.com/rust-lang/rust/issues/21195
Relevant PR: https://github.com/rust-lang/rust/pull/30778
Prior to this commit, if a compiletest testcase included the text
"HELP:" or "NOTE:" (note the colons), then it would indicate to the
compiletest suite that we should verify "help" and "note" expected
messages.
This commit updates this check to also check "HELP" and "NOTE" (not the
absense of colons) so that we always verify "help" and "note" expected
messages.
This commit implements the `make dist` command in the new rustbuild build
system, porting over `dist.mk` and `prepare.mk` into Rust. There's a huge amount
of complexity between those two files, not all of which is likely justified, so
the Rust implementation is *much* smaller.
Currently the implementation still shells out to rust-installer as well as some
python scripts, but ideally we'd rewrite it all in the future to not shell out
and be in Rust proper.
Resolve: improve diagnostics for duplicate definitions and imports
This PR improves and regularizes the diagnostics for duplicate definitions and imports.
After this PR, the second of two duplicate definitions/imports will have the following form:
> a(n) [value|type|module|trait|extern crate] named \`*name*\` has already been [defined|imported] in this [module|block|trait|enum]
with a note referencing this first of the two duplicate definitions/imports:
> previous [definition|import] of \`*name*\` here
The error indices remain unchanged.
r? @eddyb
syntax: Always pretty print a newline after doc comments
Before this patch, code that had a doc comment as the first
line, as in:
```rust
/// Foo
struct Foo;
```
Was pretty printed into:
```rust
///Foostruct Foo;
```
This makes sure that that there is always a trailing newline
after a doc comment.
Closes#31722
Normalize return type when checking for E0269
Fixes#31597
First time dealing with normalization. Maybe `normalize_associated_type` would be better here, but it seems to imply it's only used during trans.