-
-
Save bstrie/5537371 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pub enum Thing { | |
A(~Foo) | |
} | |
pub trait Foo {} | |
pub struct Struct; | |
impl Foo for Struct {} | |
pub fn new() -> Thing { | |
A(~Struct as ~Foo) | |
} | |
fn main() { | |
match new() { | |
A(a) => 0, | |
}; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment