https://gcc.gnu.org/g:e545727c840b7359fa27543c598cfa6e4a32e0ff
commit r15-9088-ge545727c840b7359fa27543c598cfa6e4a32e0ff Author: Pierre-Emmanuel Patry <pierre-emmanuel.pa...@embecosm.com> Date: Wed Mar 26 15:22:28 2025 +0100 gccrs: 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 <pierre-emmanuel.pa...@embecosm.com> Diff: --- gcc/testsuite/rust/compile/issue-2905-2.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/gcc/testsuite/rust/compile/issue-2905-2.rs b/gcc/testsuite/rust/compile/issue-2905-2.rs index 83c54ed92e5f..1c9516df9461 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<T> core::iter::IntoIterator for &[T] { + impl<T> crate::core::iter::IntoIterator for &[T] { type Item = &T; type IntoIter = Weird<T>; @@ -108,7 +108,7 @@ pub mod core { } pub mod iter { - use option::Option; + use crate::core::option::Option; pub trait IntoIterator { type Item;