You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
and function
public bool Contains(T item)
{
unsafe
{
#if NHEAP_SAFE
AtomicSafetyHandle.CheckWriteAndThrow(m_Safety);
#endif
for (int i = 0; i < _data->Count; i++)
{
var node = ReadArrayElement(_data->Heap, i);
if (item.Equals(node.Item) )
{
return true;
}
}
}
return false;
}
I did it on the spur of the moment and I don't know if it would be weird
NativeHeap<int,Min> list= new NativeHeap<int, Min>(Allocator.Temp);
list.Insert(0);
list.Insert(3);
list.Insert(5);
bool contain = list.Contains(3) // need function like this
The text was updated successfully, but these errors were encountered: