about summary refs log tree commit diff
path: root/tests/ui/rfcs/rfc-2632-const-trait-impl/const-trait-bounds-trait-objects.rs
diff options
context:
space:
mode:
authorMichael Goulet <michael@errs.io>2024-10-22 00:03:09 +0000
committerMichael Goulet <michael@errs.io>2024-10-22 00:03:09 +0000
commite91267f3f094a6f5d16aef0abb864fca4bc8c9f4 (patch)
treeba5ce9ae085572e299066b12a06da711416eea87 /tests/ui/rfcs/rfc-2632-const-trait-impl/const-trait-bounds-trait-objects.rs
parentedbd9398dcc0e3b6ffe0dd0cd4578d37d1d36974 (diff)
downloadrust-e91267f3f094a6f5d16aef0abb864fca4bc8c9f4.tar.gz
rust-e91267f3f094a6f5d16aef0abb864fca4bc8c9f4.zip
Move tests
Diffstat (limited to 'tests/ui/rfcs/rfc-2632-const-trait-impl/const-trait-bounds-trait-objects.rs')
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/const-trait-bounds-trait-objects.rs18
1 files changed, 0 insertions, 18 deletions
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/const-trait-bounds-trait-objects.rs b/tests/ui/rfcs/rfc-2632-const-trait-impl/const-trait-bounds-trait-objects.rs
deleted file mode 100644
index 691bce19dc2..00000000000
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/const-trait-bounds-trait-objects.rs
+++ /dev/null
@@ -1,18 +0,0 @@
-#![feature(const_trait_impl)]
-// FIXME(effects) add effects
-//@ edition: 2021
-
-#[const_trait]
-trait Trait {}
-
-fn main() {
-    let _: &dyn const Trait; //~ ERROR const trait bounds are not allowed in trait object types
-    let _: &dyn ~const Trait; //~ ERROR `~const` is not allowed here
-}
-
-// Regression test for issue #119525.
-trait NonConst {}
-const fn handle(_: &dyn const NonConst) {}
-//~^ ERROR const trait bounds are not allowed in trait object types
-const fn take(_: &dyn ~const NonConst) {}
-//~^ ERROR `~const` is not allowed here