-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhandle.natvis
33 lines (29 loc) · 1.5 KB
/
handle.natvis
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
<?xml version="1.0" encoding="utf-8"?>
<AutoVisualizer xmlns="http://schemas.microsoft.com/vstudio/debugger/natvis/2010">
<Type Name="Handle<*>">
<DisplayString Condition="m_intVal == kInvalid">
({ m_intVal, x }) Invalid
</DisplayString>
<DisplayString Condition="m_intVal == kInvalid || s_pool.m_nodeBuffer[m_intVal & s_pool.kIndexMask].m_version != (m_intVal >> s_pool.kIndexNumBits)">
({ m_intVal, x }) Destroyed
</DisplayString>
<DisplayString Condition="m_intVal != kInvalid && s_pool.m_nodeBuffer[m_intVal & s_pool.kIndexMask].m_version == (m_intVal >> s_pool.kIndexNumBits)">
({ m_intVal, x }) { s_pool.m_nodeBuffer[m_intVal & s_pool.kIndexMask].m_value }
</DisplayString>
<Expand>
<Item Name="[handle]">m_intVal, x</Item>
<Item Name="[index]" Condition="m_intVal != kInvalid">
m_intVal & s_pool.kIndexMask
</Item>
<Item Name="[version]" Condition="m_intVal != kInvalid">
m_intVal >> s_pool.kIndexNumBits
</Item>
<Item Name="[value]" Condition="m_intVal != kInvalid && s_pool.m_nodeBuffer[m_intVal & s_pool.kIndexMask].m_version != (m_intVal >> s_pool.kIndexNumBits)">
"Destroyed"
</Item>
<Item Name="[value]" Condition="m_intVal != kInvalid && s_pool.m_nodeBuffer[m_intVal & s_pool.kIndexMask].m_version == (m_intVal >> s_pool.kIndexNumBits)">
s_pool.m_nodeBuffer[m_intVal & s_pool.kIndexMask].m_value
</Item>
</Expand>
</Type>
</AutoVisualizer>