summaryrefslogtreecommitdiffstats
path: root/tests/ui/derives/derive-marker-tricky.rs
blob: 730ea4714c789169264e1afde7f9c5a870700aca (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// Test that `#[rustc_copy_clone_marker]` is not injected when a user-defined derive shadows
// a built-in derive in non-trivial scope (e.g. in a nested module).

// check-pass
// aux-build:derive-marker-tricky.rs

extern crate derive_marker_tricky;

mod m {
    use derive_marker_tricky::NoMarker as Copy;

    #[derive(Copy)]
    struct S;
}

fn main() {}