That's a good point. If inlining isn't a the right option in every case we would have to duplicate the implementation.
I had a look at how C++ compilers deals with this problem. They do so by duplicating the implementation in each module that instantiates the template, at least according to this document:
http://gcc.gnu.org/onlinedocs/gcc/Template-Instantiation.html
As I understand it the generated code is not exported from the translation unit so there are no collisions at link time. We could do the same if we could force the generated type class instance to not be exported from the module.