MCPcopy Create free account
hub / github.com/beefytech/Beef / GetSlotEntry

Function GetSlotEntry

IDEHelper/Compiler/BfCompiler.cpp:2797–2811  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2795typedef Dictionary<BfTypeInstance*, BfSlotEntry*> SlotEntryMap;
2796
2797static BfSlotEntry* GetSlotEntry(SlotEntryMap& slotEntryMap, BfTypeInstance* typeInst)
2798{
2799 BF_ASSERT(typeInst->IsReified());
2800
2801 BfSlotEntry** slotEntryPtr = NULL;
2802 if (!slotEntryMap.TryAdd(typeInst, NULL, &slotEntryPtr))
2803 return *slotEntryPtr;
2804
2805 BfSlotEntry* slotEntry = new BfSlotEntry();
2806 slotEntry->mTypeInstance = typeInst;
2807 slotEntry->mRefCount = 0;
2808 //insertPair.first->second = slotEntry;
2809 *slotEntryPtr = slotEntry;
2810 return slotEntry;
2811}
2812
2813static InterfacePair MakeInterfacePair(BfTypeInstance* iface1, BfTypeInstance* iface2)
2814{

Callers 1

SlowGenerateSlotNumsMethod · 0.85

Calls 2

IsReifiedMethod · 0.45
TryAddMethod · 0.45

Tested by

no test coverage detected