CL bug when compiling __hook (..)?
Hi NG,
have a nerve-racking compiler error (VC 8; CL Version 14.00.50727.42) when
using __hook (..):
[...]
void func (...)
{
__hook (&Controller::PlayCompleted, this, &ControllerImpl::EhPlayCompleted);
__hook (&Controller::ForwardCompleted, this,
&ControllerImpl::EhPlayCompleted);
__hook (&Controller::RecordCompleted, this,
&ControllerImpl::EhRecordCompleted);
__hook (&Controller::MessageCompleted, this,
&ControllerImpl::EhPlayCompleted); // <===
Compiler error C2039: 'MMessageCompleted': undefined identifier ????
__hook (&Controller::GoCompleted, this, &ControllerImpl::EhPlayCompleted);
__hook (&Controller::SkipCompleted, this, &ControllerImpl::EhPlayCompleted);
__hook (&Controller::RewindCompleted, this,
&ControllerImpl::EhPlayCompleted);
__hook (&Controller::PlayProgressChanged, this,
&ControllerImpl::EhPlayProgressChanged);
__hook (&Controller::ForwardProgressChanged, this,
&ControllerImpl::EhPlayProgressChanged);
__hook (&Controller::RewindProgressChanged, this,
&ControllerImpl::EhPlayProgressChanged);
__hook (&Controller::RecordProgressChanged, this,
&ControllerImpl::EhRecordProgressChanged);
}
[...]
compiler output:
[...]
d:\projects\lm\applications\diconcl\recorder\wio_controller\controllerimpl.cpp(764)
: error C2039: 'MMessageCompleted': Ist kein Element von
'WIO_Controller::Controller'
d:\projects\lm\applications\diconcl\recorder\wio_controller\controller.h(156):
Siehe Deklaration von 'WIO_Controller::Controller'
d:\projects\lm\applications\diconcl\recorder\wio_controller\controllerimpl.cpp(764)
: error C2065: 'MMessageCompleted': nichtdeklarierter Bezeichner
d:\projects\lm\applications\diconcl\recorder\wio_controller\controllerimpl.cpp(764)
: error C3709: '&Controller::MMessageCompleted': Ung?ltige Syntax zur
Bestimmung des Ereignisses in __hook/__unhook
[...]
As you can see I'm never using an event called 'MMessageCompleted'!
Reordering of the above sequence of statements leads to another C2039.
So, what can I do?
Thanks
Edgar