Sign in
◑
Theme
rust
/
rust
/
7bb6510fc1899b008837a376a7fdf31b341cc1bb
/
.
/
tests
/
ui
/
issues
/
issue-21332.rs
blob: 4473d00fd5da2833daf8e4024434ccf71aa48c51 [
file
]
struct
S
;
impl
Iterator
for
S
{
type
Item
=
i32
;
fn
next
(&
mut
self
)
->
Result
<
i32
,
i32
>
{
Ok
(
7
)
}
//~^ ERROR method `next` has an incompatible type for trait
//~| expected `Option<i32>`, found `Result<i32, i32>`
}
fn
main
()
{}