HttpRequest is derived from Deserializer
Works:
static String HttpRequest_String_ReadLine_void(HttpRequest* _ptr)
{
String result = _ptr->ReadLine();
return result;
}
engine->RegisterObjectMethod("HttpRequest", "String ReadLine()", asFUNCTION(HttpRequest_String_ReadLine_void), asCALL_CDECL_OBJFIRST);
Crash:
static String HttpRequest_String_ReadLine_void(Deserializer* _ptr)
{
String result = _ptr->ReadLine();
return result;
}
engine->RegisterObjectMethod("HttpRequest", "String ReadLine()", asFUNCTION(HttpRequest_String_ReadLine_void), asCALL_CDECL_OBJFIRST);
But Deserializer*
and HttpRequest*
are the same in memory. Or not?