NCAR / VAPOR

VAPOR is the Visualization and Analysis Platform for Ocean, Atmosphere, and Solar Researchers
https://www.vapor.ucar.edu/
BSD 3-Clause "New" or "Revised" License
177 stars 49 forks source link

Missing usage patterns for c++ templates implemented in cpp files #708

Open StasJ opened 6 years ago

StasJ commented 6 years ago

Templates that are defined in a header but implemented in a source file need to have their usage patterns defined otherwise the required usage patterns may not be generated and the linker will fail.

shaomeng commented 6 years ago

I'd suggest to put the implementation of template functions IN the header files.

The only drawback is larger binaries, but I don't think it's too bad, since we don't have a large number of template functions...