Should the argument to bar be a Foo<String> not an IFoo<String>?
Matthew Maycock
1

I assume you’re talking about the second snippet with bar, the one after IFoo has been introduced. In which case, what I have is correct. bar is just using the methods of foos, so it can actually accept anything that implements those methods, namely anything implementing IFoo<String>. Hope that clarifies things!

Show your support

Clapping shows how much you appreciated Ross Tate’s story.