From 218caa410aa38c29984be31a5229b9fa717560ee Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:19:13 +0200 Subject: Merging upstream version 1.68.2+dfsg1. Signed-off-by: Daniel Baumann --- tests/ui/use/auxiliary/use-from-trait-xc.rs | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 tests/ui/use/auxiliary/use-from-trait-xc.rs (limited to 'tests/ui/use/auxiliary/use-from-trait-xc.rs') diff --git a/tests/ui/use/auxiliary/use-from-trait-xc.rs b/tests/ui/use/auxiliary/use-from-trait-xc.rs new file mode 100644 index 000000000..4abe11941 --- /dev/null +++ b/tests/ui/use/auxiliary/use-from-trait-xc.rs @@ -0,0 +1,29 @@ +pub use self::sub::{Bar, Baz}; + +pub trait Trait { + fn foo(&self); + type Assoc; + const CONST: u32; +} + +struct Foo; + +impl Foo { + pub fn new() {} + + pub const C: u32 = 0; +} + +mod sub { + pub struct Bar; + + impl Bar { + pub fn new() {} + } + + pub enum Baz {} + + impl Baz { + pub fn new() {} + } +} -- cgit v1.2.3