remove unnecessary structurally_resolve_type#146637
remove unnecessary structurally_resolve_type#146637lcnr wants to merge 1 commit intorust-lang:masterfrom
structurally_resolve_type#146637Conversation
|
@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.
remove unnecessary `structurally_resolve_type`
a6ae1f4 to
c7e140b
Compare
This comment has been minimized.
This comment has been minimized.
|
Finished benchmarking commit (7b0b20b): 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.8%, secondary -1.2%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (secondary -2.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: 473.048s -> 473.468s (0.09%) |
| index_ty: Ty<'tcx>, | ||
| index_expr: &hir::Expr<'_>, | ||
| ) -> Option<(/*index type*/ Ty<'tcx>, /*element type*/ Ty<'tcx>)> { | ||
| let adjusted_ty = self.structurally_resolve_type(autoderef.span(), autoderef.final_ty()); |
There was a problem hiding this comment.
this means we no longer eagerly error on infer vars here. surprised we don't have a test for it. needs test + check for infer
There was a problem hiding this comment.
i think
fn foo() {
let x = &Default::default();
x[1];
let _: &Vec<()> = x;
}would work
|
☔ The latest upstream changes (presumably #146885) made this pull request unmergeable. Please resolve the merge conflicts. |
|
adding the test in #147180 |
…nszelmann add tests fixes rust-lang/trait-system-refactor-initiative#105 the index test is for rust-lang#146637 r? types
Rollup merge of #147180 - lcnr:forced_ambiguity-error, r=jdonszelmann add tests fixes rust-lang/trait-system-refactor-initiative#105 the index test is for #146637 r? types
the types returned by
Autoderefare always structurally resolved, cc #145990.r? @BoxyUwU