diff options
Diffstat (limited to '')
-rw-r--r-- | src/test/ui/issues/auxiliary/issue-14421.rs | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/src/test/ui/issues/auxiliary/issue-14421.rs b/src/test/ui/issues/auxiliary/issue-14421.rs new file mode 100644 index 000000000..5fe4b24cf --- /dev/null +++ b/src/test/ui/issues/auxiliary/issue-14421.rs @@ -0,0 +1,25 @@ +#![crate_type="lib"] +#![deny(warnings)] +#![allow(dead_code)] + +pub use src::aliases::B; +pub use src::hidden_core::make; + +mod src { + pub mod aliases { + use super::hidden_core::A; + pub type B = A<f32>; + } + + pub mod hidden_core { + use super::aliases::B; + + pub struct A<T> { t: T } + + pub fn make() -> B { A { t: 1.0 } } + + impl<T> A<T> { + pub fn foo(&mut self) { println!("called foo"); } + } + } +} |