]> git.lizzy.rs Git - rust.git/commitdiff
Improve test to include a projection, per @huonw's suggestion.
authorNiko Matsakis <niko@alum.mit.edu>
Mon, 5 Jan 2015 14:14:03 +0000 (09:14 -0500)
committerNiko Matsakis <niko@alum.mit.edu>
Mon, 5 Jan 2015 14:14:03 +0000 (09:14 -0500)
src/test/compile-fail/associated-type-projection-from-multiple-supertraits.rs

index 553e36f0e62dcfe15a7b903ee48dc77ec7d08d83..6555aa32027797cc32d91d78b4eebecf5f57b2a3 100644 (file)
@@ -38,4 +38,10 @@ fn dent_object<COLOR>(c: BoxCar<Color=COLOR>) {
     //~^ ERROR ambiguous associated type
 }
 
+fn paint<C:BoxCar>(c: C, d: C::Color) {
+    //~^ ERROR ambiguous associated type `Color` in bounds of `C`
+    //~| NOTE could derive from `Vehicle`
+    //~| NOTE could derive from `Box`
+}
+
 pub fn main() { }