Skip to content

Natvis: trim leading/trailing whitespace from DisplayString XML text#1571

Merged
WardenGnaw merged 1 commit into
microsoft:mainfrom
lugerard:displaystring_multiline_fix
May 27, 2026
Merged

Natvis: trim leading/trailing whitespace from DisplayString XML text#1571
WardenGnaw merged 1 commit into
microsoft:mainfrom
lugerard:displaystring_multiline_fix

Conversation

@lugerard
Copy link
Copy Markdown
Contributor

Visual Studio trims whitespace from DisplayString inner XML text before processing. MIEngine did not, causing multi-line DisplayStrings to render as blank on GDB/LLDB — the leading newline and indentation made the display appear empty in the variables panel.

Fix: call format.Trim() at the top of FormatValue() before processing.

Visual Studio trims whitespace from DisplayString inner XML text before
processing. MIEngine did not, causing multi-line DisplayStrings to render
as blank on GDB/LLDB — the leading newline and indentation made the
display appear empty in the variables panel.

Fix: call format.Trim() at the top of FormatValue() before processing.
@WardenGnaw WardenGnaw force-pushed the displaystring_multiline_fix branch from 1207412 to afc93f3 Compare May 27, 2026 16:34
@WardenGnaw WardenGnaw merged commit 5d40d57 into microsoft:main May 27, 2026
6 checks passed
@lugerard lugerard deleted the displaystring_multiline_fix branch May 28, 2026 12:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants