MCPcopy Create free account
hub / github.com/MayaPosch/NymphCast / Create

Method Create

src/server/angelscript/add_on/scriptarray/scriptarray.cpp:64–81  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

62}
63
64CScriptArray* CScriptArray::Create(asITypeInfo *ti, asUINT length)
65{
66 // Allocate the memory
67 void *mem = userAlloc(sizeof(CScriptArray));
68 if( mem == 0 )
69 {
70 asIScriptContext *ctx = asGetActiveContext();
71 if( ctx )
72 ctx->SetException("Out of memory");
73
74 return 0;
75 }
76
77 // Initialize the object
78 CScriptArray *a = new(mem) CScriptArray(length, ti);
79
80 return a;
81}
82
83CScriptArray* CScriptArray::Create(asITypeInfo *ti, void *initList)
84{

Callers

nothing calls this directly

Calls 1

SetExceptionMethod · 0.80

Tested by

no test coverage detected