From: Pierre-Emmanuel Patry Date: Wed, 26 Mar 2025 14:22:28 +0000 (+0100) Subject: Fix core library test with proper canonical path X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=b322656cdc0e3beae61be8465adab23fbcc3dbbf;p=thirdparty%2Fgcc.git Fix core library test with proper canonical path Import from core library was wrong, it misses several crate directives since we're no longer dealing with multiple files. gcc/testsuite/ChangeLog: * rust/compile/issue-2905-2.rs: Import from core library into a single file misses the crate directives. Signed-off-by: Pierre-Emmanuel Patry --- diff --git a/gcc/testsuite/rust/compile/issue-2905-2.rs b/gcc/testsuite/rust/compile/issue-2905-2.rs index 83c54ed92e5..1c9516df946 100644 --- a/gcc/testsuite/rust/compile/issue-2905-2.rs +++ b/gcc/testsuite/rust/compile/issue-2905-2.rs @@ -17,10 +17,10 @@ pub mod core { } pub mod slice { - use core::marker::PhantomData; - use core::option::Option; + use crate::core::marker::PhantomData; + use crate::core::option::Option; - impl core::iter::IntoIterator for &[T] { + impl crate::core::iter::IntoIterator for &[T] { type Item = &T; type IntoIter = Weird; @@ -108,7 +108,7 @@ pub mod core { } pub mod iter { - use option::Option; + use crate::core::option::Option; pub trait IntoIterator { type Item;