なぜ私は得るのですか:
missing template arguments before ‘(’ token
使用時:
sort(index_mu.begin(), index_mu.end(), index_cmp(mu_pt_corrected));
どこにいてどこにindex_mu
いるstd::vector<int>
mu_pt_corrected
std::vector<float>
template<class T> struct index_cmp {
index_cmp(const T arr) : arr(arr) {}
bool operator()(const size_t a, const size_t b) const
{ return arr[a] > arr[b]; }
const T arr;
};
コンパイラは の型を理解できないのT
ですか? なんで?