Skip to content

Commit 61d02fa

Browse files
committed
bless UI test
1 parent 3f42540 commit 61d02fa

File tree

2 files changed

+1
-19
lines changed

2 files changed

+1
-19
lines changed

tests/ui/inference/issue-72616.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ pub fn main() {
2121
{
2222
if String::from("a") == "a".try_into().unwrap() {}
2323
//~^ ERROR type annotations needed
24-
//~| ERROR type annotations needed
2524
}
2625
{
2726
let _: String = match "_".try_into() {

tests/ui/inference/issue-72616.stderr

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -16,23 +16,6 @@ LL - if String::from("a") == "a".try_into().unwrap() {}
1616
LL + if String::from("a") == <&str as TryInto<T>>::try_into("a").unwrap() {}
1717
|
1818

19-
error[E0283]: type annotations needed
20-
--> $DIR/issue-72616.rs:22:37
21-
|
22-
LL | if String::from("a") == "a".try_into().unwrap() {}
23-
| ^^^^^^^^
24-
|
25-
= note: multiple `impl`s satisfying `_: TryFrom<&str>` found in the following crates: `core`, `std`:
26-
- impl TryFrom<&str> for std::sys::net::connection::socket::LookupHost;
27-
- impl<T, U> TryFrom<U> for T
28-
where U: Into<T>;
29-
= note: required for `&str` to implement `TryInto<_>`
30-
help: try using a fully qualified path to specify the expected types
31-
|
32-
LL - if String::from("a") == "a".try_into().unwrap() {}
33-
LL + if String::from("a") == <&str as TryInto<T>>::try_into("a").unwrap() {}
34-
|
35-
36-
error: aborting due to 2 previous errors
19+
error: aborting due to 1 previous error
3720

3821
For more information about this error, try `rustc --explain E0283`.

0 commit comments

Comments
 (0)