summaryrefslogtreecommitdiffstats
path: root/vendor/cxx/tests/ui/vec_opaque.rs
blob: d0b279cf6841403cc4b5664790c6d841b4182156 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#[cxx::bridge]
mod handle {
    extern "C++" {
        type Job;
    }
}

#[cxx::bridge]
mod ffi1 {
    extern "C++" {
        type Job;
    }

    extern "Rust" {
        fn f() -> Vec<Job>;
    }
}

#[cxx::bridge]
mod ffi2 {
    extern "C++" {
        type Job = crate::handle::Job;
    }

    extern "Rust" {
        fn f() -> Vec<Job>;
    }
}

fn f() -> Vec<handle::Job> {
    unimplemented!()
}

fn main() {}