Problem Description
We have the following files:
RetrieveValues.hpp
:
Class RetrieveValues {
public:
RetrieveValues(){}
template<typename Comp>
static int getMinAmount(){...}
};
RetrieveValues.cpp
we have:
template RetrieveValues::<std::less<int>>getMinAmount(){...}
ComputeAmounts.cpp
int x = RetrieveValues::getMinAmount();
I followed the same as in the following question Explicit Instantiation of Template
and I got the following error error: explicit instantiation of non-template RetrieveValues. how do I fix this explicit instantiation? I Just need getMinAmount()
to be template.