Hi,
i get this error message while trying to compile rc4:
WebServer.cpp: In function `static class wxString CWebServer::_GetTransferList(ThreadData)':
WebServer.cpp:1503: ambiguous overload for `bool ? wxString & : const char[1]'
WebServer.cpp:1503: candidates are: operator ?:(bool, wxString, wxString)
WebServer.cpp:1503: operator ?:(bool, const wxChar *, const char *)
WebServer.cpp:1503: operator ?:(bool, const wxChar *, const char *)
it is this line:
Out.Replace(wxT("[ClearCompletedButton]"),(completedAv && IsSessionAdmin(Data,sSession)) ? pThis->m_Templates.sClearCompleted : wxT(""));
i rewrote this line and substituted it with the following code which compiled without error:
wxString tmp_thermoman;
if (completedAv && IsSessionAdmin(Data,sSession)) {
tmp_thermoman = pThis->m_Templates.sClearCompleted;
} else {
tmp_thermoman = wxT("");
}
Out.Replace(wxT("[ClearCompletedButton]"),tmp_thermoman);
This should be the same semantic - and it compiled well. I don't see the problem with the '?' operator. Give me a hint.
thermoman