23 if ( !
self || !method ) {
return 1; }
24 PyObject*
r = PyObject_CallMethod(
self,
const_cast<char*
>( method ),
const_cast<char*
>(
"s" ), buf );
26 std::string err(
"Unsuccessful call to bound Python method" );
28 PyErr_SetString( PyExc_TypeError, err.
c_str() );
47 for ( length = 0, x = pbase(); x < epptr(); ++x, ++length )
50 memcpy( m_callbackBuff.data(), pbase(),
std::min( length, m_callbackBuff.size() ) );
51 m_callbackBuff[
std::min( length, m_callbackBuff.size() )] =
'\0';
55 setp( pbase(), pbase() );
56 setg( eback(), eback(), eback() );