]> git.proxmox.com Git - rustc.git/blobdiff - src/test/ui/specialization/defaultimpl/validation.rs
New upstream version 1.44.1+dfsg1
[rustc.git] / src / test / ui / specialization / defaultimpl / validation.rs
index 26b3f1ec4149118ff12904b40c4feec30dff4af4..8134333c58f7305bc366d7dd83ed1ae9d78a4ebc 100644 (file)
@@ -1,4 +1,4 @@
-#![feature(optin_builtin_traits)]
+#![feature(negative_impls)]
 #![feature(specialization)]
 
 struct S;
@@ -8,8 +8,9 @@ default impl S {} //~ ERROR inherent impls cannot be `default`
 
 default unsafe impl Send for S {} //~ ERROR impls of auto traits cannot be default
 default impl !Send for Z {} //~ ERROR impls of auto traits cannot be default
+                            //~^ ERROR negative impls cannot be default impls
 
 trait Tr {}
-default impl !Tr for S {} //~ ERROR negative impls are only allowed for auto traits
+default impl !Tr for S {} //~ ERROR negative impls cannot be default impls
 
 fn main() {}