summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMike Spertus <mike@spertus.com>2016-06-05 18:34:02 +0000
committerMike Spertus <mike@spertus.com>2016-06-05 18:34:02 +0000
commit3e45d7783547aae720da2dc1e2643a93cf5f45d3 (patch)
treec955656f236c74aa635c02c964272065d9deea82
parent4d4339d1e8b5838e10458293c2afc958c9014e1b (diff)
downloadbcm5719-llvm-3e45d7783547aae720da2dc1e2643a93cf5f45d3.tar.gz
bcm5719-llvm-3e45d7783547aae720da2dc1e2643a93cf5f45d3.zip
Add Visual Studio Visualizer for ArrayRef
Modeled after visualization of llvm::SmallVec llvm-svn: 271847
-rw-r--r--llvm/utils/LLVMVisualizers/llvm.natvis13
1 files changed, 12 insertions, 1 deletions
diff --git a/llvm/utils/LLVMVisualizers/llvm.natvis b/llvm/utils/LLVMVisualizers/llvm.natvis
index 9b004832d48..6d37fa01453 100644
--- a/llvm/utils/LLVMVisualizers/llvm.natvis
+++ b/llvm/utils/LLVMVisualizers/llvm.natvis
@@ -21,7 +21,17 @@ For later versions of Visual Studio, no setup is required.
</ArrayItems>
</Expand>
</Type>
-
+ <Type Name="llvm::ArrayRef&lt;*&gt;">
+ <DisplayString Condition="Length == 0">empty</DisplayString>
+ <DisplayString Condition="Length != 0">{{ size={Length} }}</DisplayString>
+ <Expand>
+ <Item Name="[size]">Length</Item>
+ <ArrayItems>
+ <Size>Length</Size>
+ <ValuePointer>Data</ValuePointer>
+ </ArrayItems>
+ </Expand>
+ </Type>
<Type Name="llvm::SmallString&lt;*&gt;">
<DisplayString>{BeginX,s}</DisplayString>
<StringView>BeginX,s</StringView>
@@ -169,6 +179,7 @@ For later versions of Visual Studio, no setup is required.
</Expand>
</Type>
+
<!-- Since we're in MSVC, we can assume that the system is little endian. Therefore
the little and native cases just require a cast. Handle this easy case first. Use
a wildcard for the second template argument (the endianness), but we will use a
OpenPOWER on IntegriCloud