I'm trying to create a simple function which would take a static table and print it out into a file. With that in mind, I decided to use template function as follows:
template<int R, int C>
void myFunction(double (&myTable)[R][C])
{
}
And trying to call it with a simple table:
double testTable[5][5];
myFunction(phaseValuesTable);
Yet I get the following output:
error: no matching function for call to 'myFunction'
note: candidate template ignored: could not match 'double' against 'double'
What's wrong?
Aucun commentaire:
Enregistrer un commentaire