mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-18 11:34:11 +00:00
22 lines
417 B
Rust
22 lines
417 B
Rust
|
//@ check-pass
|
||
|
pub trait Archive {
|
||
|
type Archived;
|
||
|
}
|
||
|
|
||
|
impl<T> Archive for Option<T> {
|
||
|
type Archived = ();
|
||
|
}
|
||
|
pub type Archived<T> = <T as Archive>::Archived;
|
||
|
|
||
|
pub trait Deserialize<D> {}
|
||
|
|
||
|
const ARRAY_SIZE: usize = 32;
|
||
|
impl<__D> Deserialize<__D> for ()
|
||
|
where
|
||
|
Option<[u8; ARRAY_SIZE]>: Archive,
|
||
|
Option<[u8; ARRAY_SIZE]>: Archive,
|
||
|
Archived<Option<[u8; ARRAY_SIZE]>>: Deserialize<__D>,
|
||
|
{
|
||
|
}
|
||
|
fn main() {}
|