]> git.lizzy.rs Git - rust.git/blob - src/test/ui/assoc-inherent.rs
Merge commit '0eff589afc83e21a03a168497bbab6b4dfbb4ef6' into clippyup
[rust.git] / src / test / ui / assoc-inherent.rs
1 // Test that inherent associated types work with
2 // inherent_associated_types feature gate.
3
4 #![feature(inherent_associated_types)]
5 #![allow(incomplete_features)]
6
7 struct Foo;
8
9 impl Foo {
10     type Bar = isize;
11 }
12
13 impl Foo {
14     type Baz; //~ ERROR associated type in `impl` without body
15 }
16
17 fn main() {
18     let x : Foo::Bar; //~ERROR ambiguous associated type
19     x = 0isize;
20 }