D
Daniel
Here is the code in question:
switch (msgtype)
{
MSG_S_LOGIN_FAIL :
// TODO
// display msg
//
break;
MSG_S_LOGGED_ON :
// TODO
// start
break;
MSG_S_REG_FAIL :
// TODO
// display msg
break;
MSG_S_REGISTERED :
// TODO
// start
//
break;
}
....and here are the warnings:
$ make
g++ -Wall -g -o0 client.cpp player.cpp -o tbclient.exe
client.cpp: In member function `void TClient::RecvMsg()':
client.cpp:69: warning: label `MSG_S_REGISTERED' defined but not used
client.cpp:65: warning: label `MSG_S_REG_FAIL' defined but not used
client.cpp:61: warning: label `MSG_S_LOGGED_ON' defined but not used
client.cpp:56: warning: label `MSG_S_LOGIN_FAIL' defined but not used
Here are the declarations:
const char MSG_S_LOGIN_FAIL = 'l';
const char MSG_S_LOGGED_ON = 'L';
const char MSG_S_REG_FAIL = 'r';
const char MSG_S_REGISTERED = 'R';
switch (msgtype)
{
MSG_S_LOGIN_FAIL :
// TODO
// display msg
//
break;
MSG_S_LOGGED_ON :
// TODO
// start
break;
MSG_S_REG_FAIL :
// TODO
// display msg
break;
MSG_S_REGISTERED :
// TODO
// start
//
break;
}
....and here are the warnings:
$ make
g++ -Wall -g -o0 client.cpp player.cpp -o tbclient.exe
client.cpp: In member function `void TClient::RecvMsg()':
client.cpp:69: warning: label `MSG_S_REGISTERED' defined but not used
client.cpp:65: warning: label `MSG_S_REG_FAIL' defined but not used
client.cpp:61: warning: label `MSG_S_LOGGED_ON' defined but not used
client.cpp:56: warning: label `MSG_S_LOGIN_FAIL' defined but not used
Here are the declarations:
const char MSG_S_LOGIN_FAIL = 'l';
const char MSG_S_LOGGED_ON = 'L';
const char MSG_S_REG_FAIL = 'r';
const char MSG_S_REGISTERED = 'R';