diff options
Diffstat (limited to 'gcc/testsuite/rust/compile/issue-2954.rs')
-rw-r--r-- | gcc/testsuite/rust/compile/issue-2954.rs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/gcc/testsuite/rust/compile/issue-2954.rs b/gcc/testsuite/rust/compile/issue-2954.rs new file mode 100644 index 0000000..52f7c91 --- /dev/null +++ b/gcc/testsuite/rust/compile/issue-2954.rs @@ -0,0 +1,17 @@ +#[lang = "sized"] +trait Sized {} + +#[lang = "receiver"] +#[unstable(feature = "receiver_trait", issue = "none")] +// #[doc(hidden)] +pub trait Receiver { + // Empty. +} + +#[unstable(feature = "receiver_trait", issue = "none")] +impl<T: ?Sized> Receiver for &T {} + +#[unstable(feature = "receiver_trait", issue = "none")] +impl<T: ?Sized> Receiver for &mut T {} + + |