From 3b1c98bda622e4d2d5488d8549c947e44f274ffc Mon Sep 17 00:00:00 2001 From: ridwanabdillahi <91507758+ridwanabdillahi@users.noreply.github.com> Date: Wed, 28 Sep 2022 15:02:15 -0700 Subject: [PATCH] Update the Natvis definiton for `HSTRING` to rely on the memory layout of Natvis as opposed to the internal data structure. --- crates/libs/windows/windows.natvis | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/crates/libs/windows/windows.natvis b/crates/libs/windows/windows.natvis index 71574e1fde..9300c81374 100644 --- a/crates/libs/windows/windows.natvis +++ b/crates/libs/windows/windows.natvis @@ -27,18 +27,20 @@ - "" - {((char16_t*)__0->data),[__0->len]su} + + + "" + {((char16_t*)header()->data),[header()->len]su} - __0 == nullptr ? (unsigned int)0 : __0->len - __0->count - __0->flags - + is_empty() ? (unsigned int)0 : header()->len + header()->count + header()->flags + - __0->len - (char16_t*)__0->data + header()->len + (char16_t*)header()->data