-
Notifications
You must be signed in to change notification settings - Fork 14k
TypeRelating emit WellFormed, not generalize #148823
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
base: main
Are you sure you want to change the base?
Conversation
|
changes to the core type system |
|
|
|
@bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
TypeRelating emit WellFormed, not generalize
This comment has been minimized.
This comment has been minimized.
|
Finished benchmarking commit (20a081a): comparison URL. Overall result: ❌✅ regressions and improvements - please read the text belowBenchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf. Next Steps: If you can justify the regressions found in this try perf run, please do so in sufficient writing along with @bors rollup=never Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (secondary 1.2%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (primary 2.3%, secondary 10.1%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 477.625s -> 479.621s (0.42%) |
aafb23b to
3bc3788
Compare
|
@bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
TypeRelating emit WellFormed, not generalize
84fb939 to
282f7fe
Compare
This comment has been minimized.
This comment has been minimized.
282f7fe to
929f6e2
Compare
This comment has been minimized.
This comment has been minimized.
|
Finished benchmarking commit (3d1dd7d): comparison URL. Overall result: ❌✅ regressions and improvements - please read the text belowBenchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf. Next Steps: If you can justify the regressions found in this try perf run, please do so in sufficient writing along with @bors rollup=never Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (primary 1.5%, secondary 0.4%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (primary 2.8%, secondary 3.6%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 474.976s -> 475.327s (0.07%) |
929f6e2 to
c137984
Compare
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
|
@bors try @rust-timer queue let's try to get the addition of |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
TypeRelating emit WellFormed, not generalize
This comment has been minimized.
This comment has been minimized.
|
Finished benchmarking commit (c68c666): comparison URL. Overall result: ✅ improvements - no action neededBenchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf. @bors rollup=never Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)This benchmark run did not return any relevant results for this metric. CyclesResults (primary -2.9%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeResults (primary -1.1%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Bootstrap: 474.258s -> 474.449s (0.04%) |
c137984 to
1e593fd
Compare
|
@bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
TypeRelating emit WellFormed, not generalize
This comment has been minimized.
This comment has been minimized.
|
Finished benchmarking commit (898f13c): comparison URL. Overall result: ✅ improvements - no action neededBenchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf. @bors rollup=never Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (primary 1.9%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (secondary 3.7%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 472.838s -> 476.429s (0.76%) |
| | | ||
| = note: requirement occurs because of the type `S<dyn Cat<'_>>`, which makes the generic argument `dyn Cat<'_>` invariant | ||
| = note: the struct `S<T>` is invariant over the parameter `T` | ||
| = help: see <https://doc.rust-lang.org/nomicon/subtyping.html> for more information about variance |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is the perf win we get from making this diagnostic worse, necessary to land this PR? I don't like this diagnostic change and think it was signfiicantly better before. Variance is subtle and it seems quite valuable to me to be explicitly telling people that they have lifetime issues due to variance
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This diagnostics change is 1e593fd and imo the current diagnostic relies on a bug. If we're already in an invariant context, the fact that S is invariant over T doesn't matter.
I do still need to add tests for the fixed next-solver behavior before merging this PR regardless.
fixes rust-lang/trait-system-refactor-initiative#250
r? BoxyUwU