blob: 9bdcc9ac42a7a2dd4211cca3ae2bda77437f0393 [file] [log] [blame]
trait Generator {
fn create() -> u32;
}
struct Impl;
impl Generator for Impl {
fn create() -> u32 { 1 }
}
struct AnotherImpl;
impl Generator for AnotherImpl {
fn create() -> u32 { 2 }
}
fn main() {
let cont: u32 = Generator::create(); //~ ERROR E0283
}