How do I export templated classes from a dll without explicit specification?

Since the code for templates is usually in headers, you don’t need to export the functions at all. That is, the library that is using the dll can instantiate the template.

This is the only way to give users the freedom to use any type with the template, but in a sense it’s working against the way dlls are supposed to work.

Leave a Comment