Closed
Description
#![crate_type="lib"]
enum Foo {
}
impl Clone for Foo {
fn clone(&self) -> Foo { loop {} }
}
This code emits no warnings because impl Clone for Foo
is considered a "use" of the enum, however, implementation for this enum cannot possibly be used either, as the enum is private and is unused. This is more notable for derive
d implementations, which also inhibit this lint.
The inherent implementations behave as expected.