- generate error instead of warning
- remove `RewindPoint` and just keep a copy of `Parser` to rewind state.
- `dont_parse_generics: bool` -> `parse_generics: bool`
- remove `eat_lt`
- move error handling code to separate method
Clearer use of the error message and span labels to communicate
duplicaiton defitions/imports.
New error format:
```
error[E0428]: the name `Foo` is defined twice
--> example.rs:2:1
|
1 | trait Foo { }
| ------------- previous definition of the trait `Foo` here
2 | struct Foo { }
| ^^^^^^^^^^^^^^ `Foo` redefined here
= note: `Foo` must be defined only once in the type namespace of this module
error: aborting due to previous error
```
incr.comp.: Make DepNode's std::fmt::Debug implementation useful again.
With #42537 a regular `DepNode` only contains an opaque hash as its identifier. In most cases, this hash is actually a `DefPathHash` and we can reconstruct the `DefId` it came from via a table lookup --- and then use that to print something intelligible for debug outputs. For cases where we cannot reconstruct information from the DepNode's hash, this PR will cache a string representation of the `DepNode` in a side-table. This string is later used for debug outputs.
r? @nikomatsakis
For code like `if x = 3 {}`, output:
```
error[E0308]: mismatched types
--> $DIR/issue-17283.rs:25:8
|
25 | if x = x {
| ^^^^^
| |
| help: did you mean to compare equality? `x == x`
| expected bool, found ()
|
= note: expected type `bool`
found type `()`
```
Instead of suppressing only trait errors that are "exact duplicates",
display only the "most high-level" error when there are multiple trait
errors with the same span that imply each-other.
e.g. when there are both `[closure]: Fn` and `[closure]: FnOnce`, omit
displaying the `[closure]: FnOnce` bound.
Refactor ops.rs
This refactors ops.rs into several different modules internally, as the file has gotten quite big. None of these modules are actually exported, but this should make maintaining it much easier. I've avoided the ambition of exporting the modules because they can more easily be rearranged after this commit goes through, even though it'd be cool to potentially export the modules in the future.
I've separated the creation of each file into a separate commit so that this is easier to read.
Redone version of #42269 with the movement of `RangeArgument` moved.
Build instruction profiler runtime as part of compiler-rt
r? @alexcrichton
This is #38608 with some fixes.
Still missing:
- [x] testing with profiler enabled on some builders (on which ones? Should I add the option to some of the already existing configurations, or create a new configuration?);
- [x] enabling distribution (on which builders?);
- [x] documentation.