I'm having some trouble passing a 2d array from my .cpp file to a header file
My function in my .cpp file looks like void Lab::logoff(int (&arr)[arrC][arrR])
and my pass to my class looks like this:
1 2 3 4 5
class Lab{
publicint logoff(int (&arr)[3][5]) const;
}
And I'm getting the error:
1 2 3 4 5 6 7
/home/ubuntu/workspace/Lab.cpp:148:6: error: prototype for βvoid Lab::logoff(int (&)[3][5])β does not match any in class βLabβ
void Lab::logoff(int (&arr)[arrC][arrR])
In file included from /home/ubuntu/workspace/Lab.cpp:5:0:
/home/ubuntu/workspace/Lab.h:60:7: error: candidate is: int Lab::logoff(int (&)[3][5]) constint logoff(int (&)[3][5]) const;