https://gcc.gnu.org/g:1786c4fcb1caea99000c7c874f88688713a6b661

commit 1786c4fcb1caea99000c7c874f88688713a6b661
Author: Pierre-Emmanuel Patry <pierre-emmanuel.pa...@embecosm.com>
Date:   Mon Nov 20 14:16:41 2023 +0100

    Add a regression test for super trait on auto trait
    
    Add a new regression test to highlight the error behavior with a super
    trait on an auto trait.
    
    gcc/testsuite/ChangeLog:
    
            * rust/compile/auto_trait_super_trait.rs: New test.
    
    Signed-off-by: Pierre-Emmanuel Patry <pierre-emmanuel.pa...@embecosm.com>

Diff:
---
 gcc/testsuite/rust/compile/auto_trait_super_trait.rs | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/gcc/testsuite/rust/compile/auto_trait_super_trait.rs 
b/gcc/testsuite/rust/compile/auto_trait_super_trait.rs
new file mode 100644
index 000000000000..1080afb5124d
--- /dev/null
+++ b/gcc/testsuite/rust/compile/auto_trait_super_trait.rs
@@ -0,0 +1,4 @@
+trait Cold {}
+
+auto trait IsCool: Cold {}
+// { dg-error "auto traits cannot have super traits .E0568." "" { target *-*-* 
} .-1 }

Reply via email to