about summary refs log tree commit diff
path: root/compiler
diff options
context:
space:
mode:
authorYiming Lei <yiming.lei@futurewei.com>2022-10-04 10:30:25 -0700
committerYiming Lei <yiming.lei@futurewei.com>2022-10-04 10:30:25 -0700
commit4f3b6ac91f58a2b1dbce8f8b967ceed0edd2f136 (patch)
tree98e4a5bc77cf312445e9b88ece585bd001a2e47a /compiler
parent02cd79afb8080fce8c8ce35533c54d8ecf8f390e (diff)
downloadrust-4f3b6ac91f58a2b1dbce8f8b967ceed0edd2f136.tar.gz
rust-4f3b6ac91f58a2b1dbce8f8b967ceed0edd2f136.zip
follow-up fix about 101866 to print the self type.
	modified:   compiler/rustc_trait_selection/src/traits/error_reporting/mod.rs
	modified:   src/test/ui/error-codes/E0283.stderr
	modified:   src/test/ui/error-codes/E0790.stderr
	modified:   src/test/ui/traits/static-method-generic-inference.stderr
	modified:   src/test/ui/type/issue-101866.stderr
Diffstat (limited to 'compiler')
-rw-r--r--compiler/rustc_trait_selection/src/traits/error_reporting/mod.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_trait_selection/src/traits/error_reporting/mod.rs b/compiler/rustc_trait_selection/src/traits/error_reporting/mod.rs
index 5fdadd0b4b4..e694151d503 100644
--- a/compiler/rustc_trait_selection/src/traits/error_reporting/mod.rs
+++ b/compiler/rustc_trait_selection/src/traits/error_reporting/mod.rs
@@ -2265,7 +2265,7 @@ impl<'a, 'tcx> InferCtxtPrivExt<'a, 'tcx> for InferCtxt<'a, 'tcx> {
                             };
                             let mut suggestions = vec![(
                                 trait_path_segment.ident.span.shrink_to_lo(),
-                                format!("<{} as ", self.tcx.def_path(impl_def_id).to_string_no_crate_verbose())
+                                format!("<{} as ", self.tcx.type_of(impl_def_id))
                             )];
                             if let Some(generic_arg) = trait_path_segment.args {
                                 let between_span = trait_path_segment.ident.span.between(generic_arg.span_ext);