struct Bar { bar: T } enum Foo{ Tup() } impl Foo { fn foo() { } } fn main() { let thing = Bar { bar: Foo::Tup }; thing.bar.foo(); //~^ ERROR no method named `foo` found for fn item `fn() -> Foo {Foo::Tup}` in the current scope [E0599] }