rust/tests/ui/builtin-superkinds/builtin-superkinds-in-metadata2.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

24 lines
581 B
Rust
Raw Normal View History

// run-pass
#![allow(unused_imports)]
2013-08-16 17:21:02 -05:00
// aux-build:trait_superkinds_in_metadata.rs
2013-08-19 16:15:25 -05:00
// Tests (correct) usage of trait super-builtin-kinds cross-crate.
extern crate trait_superkinds_in_metadata;
use trait_superkinds_in_metadata::{RequiresRequiresShareAndSend, RequiresShare};
use trait_superkinds_in_metadata::RequiresCopy;
use std::marker;
2013-08-16 17:21:02 -05:00
2015-03-30 08:38:27 -05:00
#[derive(Copy, Clone)]
2022-07-25 15:36:03 -05:00
struct X<T>(#[allow(unused_tuple_struct_fields)] T);
2013-08-16 17:21:02 -05:00
impl<T:Sync> RequiresShare for X<T> { }
2013-08-16 17:21:02 -05:00
impl<T:Sync+Send> RequiresRequiresShareAndSend for X<T> { }
impl<T:Copy> RequiresCopy for X<T> { }
pub fn main() { }