Tool/software: TI C/C++ Compiler
Hi all,
When I tried to use std::function and convert it to pointer:
const std::function<bStatus_t(uint16 connHandle,
gattAttribute_t *pAttr,
uint8 *pValue,
uint16 *pLen,
uint16 offset,
uint16 maxLen,
uint8 method)>
kReadAttrCB = std::bind(&Service::ReadAttrCB, this,
std::placeholders::_1,
std::placeholders::_2,
std::placeholders::_3,
std::placeholders::_4,
std::placeholders::_5,
std::placeholders::_6,
std::placeholders::_7);
auto pf = kReadAttrCB.target<bStatus_t(*)( uint16 connHandle, gattAttribute_t *pAttr,
uint8 *pValue, uint16 *pLen, uint16 offset,
uint16 maxLen, uint8 method )>();
I have got the following error:
"../Profiles/service.cpp", line 243: error #136: class "std::__2::function<bStatus_t (uint16, gattAttribute_t *, uint8 *, uint16 *, uint16, uint16, uint8)>" has no member "target"
Is it a bug of compiler ?