2019-04-05 07:22:36 +02:00
|
|
|
// run-pass
|
|
|
|
|
2018-07-30 11:33:44 +02:00
|
|
|
#![deny(clippy::all)]
|
2016-11-10 17:06:39 +01:00
|
|
|
|
2019-02-06 07:45:57 +01:00
|
|
|
/// Test for https://github.com/rust-lang/rust-clippy/issues/1336
|
|
|
|
|
2016-11-10 17:06:39 +01:00
|
|
|
#[allow(dead_code)]
|
|
|
|
struct Foo;
|
|
|
|
|
|
|
|
impl Iterator for Foo {
|
|
|
|
type Item = ();
|
|
|
|
|
|
|
|
fn next(&mut self) -> Option<()> {
|
|
|
|
let _ = self.len() == 0;
|
|
|
|
unimplemented!()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-12-20 10:20:41 +01:00
|
|
|
impl ExactSizeIterator for Foo {}
|
2018-05-11 13:20:39 +02:00
|
|
|
|
|
|
|
fn main() {}
|