Revert "feat: Diagnose some incorrect usages of the question mark operator"

This commit is contained in:
Lukas Wirth 2022-10-18 14:18:59 +02:00 committed by GitHub
parent 4d4c05d32b
commit 8047512dca
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
13 changed files with 125 additions and 289 deletions

View file

@ -4913,22 +4913,6 @@ fn foo() -> NotResult<(), Short> {
```
"#]],
);
check_hover_range(
r#"
//- minicore: try
use core::ops::ControlFlow;
fn foo() -> ControlFlow<()> {
$0ControlFlow::Break(())?$0;
ControlFlow::Continue(())
}
"#,
expect![[r#"
```text
Try Target Type: ControlFlow<(), {unknown}>
Propagated as: ControlFlow<(), ()>
```
"#]],
);
}
#[test]
@ -4944,9 +4928,9 @@ fn foo() -> Option<()> {
}
"#,
expect![[r#"
```rust
i32
```"#]],
```rust
<Option<i32> as Try>::Output
```"#]],
);
}