summaryrefslogtreecommitdiffstats
path: root/src/test/ui/rmeta/rmeta_meta_main.rs
blob: 839f350d7413090929286d6b9cf35e28c26b6c12 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// compile-flags: --emit=metadata
// aux-build:rmeta-meta.rs
// no-prefer-dynamic

// Check that building a metadata crate finds an error with a dependent,
// metadata-only crate.


extern crate rmeta_meta;
use rmeta_meta::Foo;

fn main() {
    let _ = Foo { field2: 42 }; //~ ERROR struct `Foo` has no field named `field2`
}