]> git.lizzy.rs Git - rust.git/blob - src/test/ui/coherence/coherence_local_ref.rs
Rollup merge of #57107 - mjbshaw:thread_local_test, r=nikomatsakis
[rust.git] / src / test / ui / coherence / coherence_local_ref.rs
1 // Test that we are able to introduce a negative constraint that
2 // `MyType: !MyTrait` along with other "fundamental" wrappers.
3
4 // aux-build:coherence_copy_like_lib.rs
5 // compile-pass
6 // skip-codegen
7 // revisions: old re
8
9 #![cfg_attr(re, feature(re_rebalance_coherence))]
10 #![allow(dead_code)]
11
12 extern crate coherence_copy_like_lib as lib;
13
14 struct MyType { x: i32 }
15
16 // naturally, legal
17 impl lib::MyCopy for MyType { }
18
19
20 fn main() { }