-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathgstd.natvis
37 lines (34 loc) · 1.73 KB
/
gstd.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
34
35
36
37
<?xml version="1.0" encoding="utf-8"?>
<AutoVisualizer xmlns="http://schemas.microsoft.com/vstudio/debugger/natvis/2010">
<Type Name="gstd::script_vector<*>">
<Intrinsic Name="size" Expression="length" />
<Intrinsic Name="capacity" Expression="capacity" />
<DisplayString>{{ size={size()}, capacity={capacity} }}</DisplayString>
<Expand>
<Item Name="[capacity]" ExcludeView="simple">capacity</Item>
<ArrayItems>
<Size>capacity</Size>
<ValuePointer>at</ValuePointer>
</ArrayItems>
</Expand>
</Type>
<!--
Somehow doesn't work
<Type Name="gstd::value::body">
<Intrinsic Name="_type" Expression="(int)(type->get_kind())"/>
<Intrinsic Name="_element" Expression="(int)(type->get_element()->get_kind())"/>
<DisplayString Condition="(this == nullptr)">empty</DisplayString>
<DisplayString Condition="(this != nullptr)" Optional="true">{{ ref_count={use_count()} }}</DisplayString>
<Expand>
<Item Condition="_type == 0" Name="[real]" Optional="true" ExcludeView="simple">{{ value={this->real_value} }}</Item>
<Item Condition="_type == 1" Name="[char]" Optional="true" ExcludeView="simple">{{ value={this->char_value} }}</Item>
<Item Condition="_type == 2" Name="[bool]" Optional="true" ExcludeView="simple">{{ value={this->boolean_value} }}</Item>
<Item Condition="_type == 3" Name="[array]" Optional="true" ExcludeView="simple">{{ size={this->array_value.size()} }}</Item>
<ArrayItems Condition="_type == 3 && _element != 1" Optional="true" ExcludeView="simple">
<Size>this->array_value.size()</Size>
<ValuePointer>this->array_value.data()</ValuePointer>
</ArrayItems>
</Expand>
</Type>
-->
</AutoVisualizer>