mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-25 00:03:43 +00:00
38d4ac7cea
Discussion previously happened in https://github.com/rust-lang/rust/pull/43498
23 lines
374 B
Rust
23 lines
374 B
Rust
use std::fmt;
|
|
use std::marker::PhantomData;
|
|
|
|
pub struct Key<T> {
|
|
#[doc(hidden)]
|
|
pub __name: &'static str,
|
|
#[doc(hidden)]
|
|
pub __phantom: PhantomData<T>,
|
|
}
|
|
|
|
impl<T> Copy for Key<T> {}
|
|
|
|
impl<T> Clone for Key<T> {
|
|
fn clone(&self) -> Self {
|
|
Key {
|
|
__name: self.__name,
|
|
__phantom: self.__phantom,
|
|
}
|
|
}
|
|
}
|
|
|
|
fn main() {}
|