[COMMITTED 14/19] gccrs: testsuite: Add a testcase for issue 4158

arthur.cohen@embecosm.com arthur.cohen@embecosm.com
Mon Jun 1 13:40:52 GMT 2026


From: Harishankar <harishankarpp7@gmail.com>

gcc/testsuite/ChangeLog:
	* rust/compile/issue-4158.rs: New test.
Signed-off-by: Harishankar <harishankarpp7@gmail.com>
---
 gcc/testsuite/rust/compile/issue-4158.rs | 3 +++
 1 file changed, 3 insertions(+)
 create mode 100644 gcc/testsuite/rust/compile/issue-4158.rs

diff --git a/gcc/testsuite/rust/compile/issue-4158.rs b/gcc/testsuite/rust/compile/issue-4158.rs
new file mode 100644
index 00000000000..f0fa5f56430
--- /dev/null
+++ b/gcc/testsuite/rust/compile/issue-4158.rs
@@ -0,0 +1,3 @@
+#![feature(no_core)]
+#![no_core]
+struct A<const B: A = 1, A>; // { dg-error "invalid order for generic parameters" }
\ No newline at end of file
-- 
2.50.1



More information about the Gcc-rust mailing list