Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- typedef std::function<void(std::shared_ptr<TimerExpiryInd>)> DefTimerExpiryHandler;
- std::map< int, DefTimerExpiryHandler > m_timerFSMMap;
- template<class FSM>
- uint32_t startTimer( uint32_t expiryMs, int timerId, FSM& sm )
- {
- m_timerFSMMap[timerId] = std::bind(&FSM::process_event, &sm,
- std::placeholders::_1);
- }
- struct handleRsp
- {
- template <class FSM, class SourceState, class TargetState>
- void operator()(std::shared_ptr<RspWrapper> const& evt, FSM& fsm,
- SourceState& srcState, TargetState& dstState)
- {
- int timerPeriod = 1000 ;
- #define TIMER 1
- startTimer <FSM> ( timerPeriod, TIMER, fsm );
- }
- };
- error: no matching function for call to 'bind'
- m_timerFSMMap[timerId] = std::bind(&FSM::process_event, this, std::placehold
- ers::_1);
- c:Program Files (x86)Microsoft Visual Studio2017ProfessionalVCToolsMSVC1
- 4.12.25827includefunctional(1092,37): note: candidate template ignored: could
- n't infer template argument '_Fx'
- _Binder<_Unforced, _Fx, _Types...> bind(_Fx&& _Func, _Types&&... _Args)
- ^
- c:Program Files (x86)Microsoft Visual Studio2017ProfessionalVCToolsMSVC1
- 4.12.25827includefunctional(1101,32): note: candidate template ignored: could
- n't infer template argument '_Ret'
- _Binder<_Ret, _Fx, _Types...> bind(_Fx&& _Func, _Types&&... _Args)
- ^
Add Comment
Please, Sign In to add comment