2018-08-30 07:18:55 -05:00
|
|
|
// run-pass
|
2018-09-25 16:51:35 -05:00
|
|
|
#![allow(dead_code)]
|
2015-03-22 15:13:15 -05:00
|
|
|
// pretty-expanded FIXME #23616
|
|
|
|
|
2014-10-19 01:46:08 -05:00
|
|
|
pub use Foo::*;
|
|
|
|
use nest::{Bar, D, E, F};
|
|
|
|
|
|
|
|
pub enum Foo {
|
|
|
|
A,
|
2015-03-25 19:06:52 -05:00
|
|
|
B(isize),
|
|
|
|
C { a: isize },
|
2014-10-19 01:46:08 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
impl Foo {
|
|
|
|
pub fn foo() {}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn _f(f: Foo) {
|
|
|
|
match f {
|
|
|
|
A | B(_) | C { .. } => {}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
mod nest {
|
|
|
|
pub use self::Bar::*;
|
|
|
|
|
|
|
|
pub enum Bar {
|
|
|
|
D,
|
2015-03-25 19:06:52 -05:00
|
|
|
E(isize),
|
|
|
|
F { a: isize },
|
2014-10-19 01:46:08 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
impl Bar {
|
|
|
|
pub fn foo() {}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn _f2(f: Bar) {
|
|
|
|
match f {
|
|
|
|
D | E(_) | F { .. } => {}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|