diff options
| author | Manish Goregaokar <manishsmail@gmail.com> | 2020-06-18 15:20:57 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-06-18 15:20:57 -0700 |
| commit | 9ca811772c2fddefeda4567cdfb8c790c94e0085 (patch) | |
| tree | a4ede3c4340f0e6bbe965db8098227aa1c5a2943 /src/libcore | |
| parent | f4b5f581a9c2604a951043decd6acf4e2852fe35 (diff) | |
| parent | e857696cf8c3b4a4381d00424f165c10f93a9ebd (diff) | |
| download | rust-9ca811772c2fddefeda4567cdfb8c790c94e0085.tar.gz rust-9ca811772c2fddefeda4567cdfb8c790c94e0085.zip | |
Rollup merge of #73361 - estebank:non-primitive-cast, r=davidtwco
Tweak "non-primitive cast" error - Suggest borrowing expression if it would allow cast to work. - Suggest using `<Type>::from(<expr>)` when appropriate. - Minor tweak to `;` typo suggestion. Partily address #47136.
Diffstat (limited to 'src/libcore')
| -rw-r--r-- | src/libcore/convert/mod.rs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/libcore/convert/mod.rs b/src/libcore/convert/mod.rs index eef9ee7cb00..8ff1ced53b0 100644 --- a/src/libcore/convert/mod.rs +++ b/src/libcore/convert/mod.rs @@ -374,6 +374,7 @@ pub trait Into<T>: Sized { /// [`Into`]: trait.Into.html /// [`from`]: trait.From.html#tymethod.from /// [book]: ../../book/ch09-00-error-handling.html +#[rustc_diagnostic_item = "from_trait"] #[stable(feature = "rust1", since = "1.0.0")] #[rustc_on_unimplemented(on( all(_Self = "&str", T = "std::string::String"), |
