Der Code istC++ Eclipse-sagt ungültige Argumente (Typ nicht korrekt)
g_CDioService->getDioPrjMgr()->NotifyBtMacAddress(std::string(path));
Deklaration
void NotifyBtMacAddress(const std::string &path);
Eclipse-NotifyBtMacAddress
unterstreicht und sagt
Invalid arguments 'Candidates are: void NotifyBtMacAddress(const ? &)'
ich auch versucht habe zu explizit auf den tatsächlich erwarteten Typ umwandeln:
g_CDioService->getDioPrjMgr()->NotifyBtMacAddress(const_cast<const std::string & >(std::string(path)));
Aber gibt immer noch die gleiche (rot unterstrichen) Fehler/Warnung.
Ich habe Zugriff auf die Quelle der Funktion
void CDioPrjMgr::NotifyBtMacAddress(const std::string &path){
// PASLOG(ZONE_FUNC, __FUNCTION__, "Sequence: PRJ_DIO -> PRJ_Manager : Send BT MAC ADdress");
// On recving Disable BT command, Send Mac Addres to Mgr.
...
@JonnyHenly ist der Code in Ordnung. Ich möchte wissen, warum Eclipse denkt, dass es nicht ist. – Adrian
Sie bekommen das, wenn Sie das Projekt erstellen oder während Sie tippen? – gsamaras
Haben Sie die Methode definiert oder stammt sie aus einer Bibliothek? –