MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / createLocalEntry

Method createLocalEntry

Engine/source/console/consoleInternal.cpp:1210–1231  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1208}
1209
1210Namespace::Entry *Namespace::createLocalEntry(StringTableEntry name)
1211{
1212 for (Entry *walk = mEntryList; walk; walk = walk->mNext)
1213 {
1214 if (walk->mFunctionName == name)
1215 {
1216 walk->clear();
1217 return walk;
1218 }
1219 }
1220
1221 Entry *ent = (Entry *)mAllocator.alloc(sizeof(Entry));
1222 constructInPlace(ent);
1223
1224 ent->mNamespace = this;
1225 ent->mFunctionName = name;
1226 ent->mNext = mEntryList;
1227 ent->mPackage = mPackage;
1228 ent->mToolOnly = false;
1229 mEntryList = ent;
1230 return ent;
1231}
1232
1233void Namespace::addFunction(StringTableEntry name, CodeBlock *cb, U32 functionOffset, const char* usage, U32 lineNumber)
1234{

Callers

nothing calls this directly

Calls 3

constructInPlaceFunction · 0.85
clearMethod · 0.45
allocMethod · 0.45

Tested by

no test coverage detected