MCPcopy Create free account
hub / github.com/HaxeFoundation/hxcpp / alloc_string_data

Function alloc_string_data

src/hx/CFFI.cpp:425–434  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

423
424
425char *alloc_string_data(const char *inData, int inLength)
426{
427 char *result = (char *)hx::NewGCBytes(0,inLength+1);
428 if (inData)
429 {
430 memcpy(result, inData, inLength);
431 result[inLength] = 0;
432 }
433 return result;
434}
435
436hx::Object *alloc_string_len(const char *inStr,int inLen)
437{

Callers 1

HxStringMethod · 0.85

Calls 2

NewGCBytesFunction · 0.85
memcpyFunction · 0.85

Tested by

no test coverage detected