mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-23 07:14:28 +00:00
15 lines
276 B
Rust
15 lines
276 B
Rust
#![feature(discriminant_kind)]
|
|
|
|
use std::marker::DiscriminantKind;
|
|
|
|
enum Uninhabited {}
|
|
|
|
struct NewType;
|
|
|
|
impl DiscriminantKind for NewType {
|
|
//~^ ERROR explicit impls for the `DiscriminantKind` trait are not permitted
|
|
type Discriminant = Uninhabited;
|
|
}
|
|
|
|
fn main() {}
|