rust/src/test/ui/impl-trait/bindings-opaque.rs
2018-12-25 21:08:33 -07:00

17 lines
291 B
Rust

#![feature(impl_trait_in_bindings)]
const FOO: impl Copy = 42;
static BAR: impl Copy = 42;
fn main() {
let foo: impl Copy = 42;
let _ = FOO.count_ones();
//~^ ERROR no method
let _ = BAR.count_ones();
//~^ ERROR no method
let _ = foo.count_ones();
//~^ ERROR no method
}