2015-01-06 17:07:56 -06:00
|
|
|
// issue #20126
|
|
|
|
|
2023-03-07 17:55:51 -06:00
|
|
|
#[derive(Copy, Clone)] //~ ERROR the trait `Copy` cannot be implemented
|
2015-01-06 17:07:56 -06:00
|
|
|
struct Foo;
|
|
|
|
|
|
|
|
impl Drop for Foo {
|
|
|
|
fn drop(&mut self) {}
|
|
|
|
}
|
|
|
|
|
2023-03-07 17:55:51 -06:00
|
|
|
#[derive(Copy, Clone)] //~ ERROR the trait `Copy` cannot be implemented
|
2015-02-12 09:29:52 -06:00
|
|
|
struct Bar<T>(::std::marker::PhantomData<T>);
|
2015-01-06 17:07:56 -06:00
|
|
|
|
|
|
|
impl<T> Drop for Bar<T> {
|
|
|
|
fn drop(&mut self) {}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|