tinyxml2 icon indicating copy to clipboard operation
tinyxml2 copied to clipboard

Add tinyxml2.natvis for debugging

Open Caerind opened this issue 3 years ago • 2 comments

Hi !

I was debugging some elements today and I wanted better visualization.

I found this : https://github.com/cdcseacave/Visual-Studio-Visualizers/blob/master/TinyXML2.natvis

I think it could be added directly in the main repo.

Caerind avatar Apr 07 '22 16:04 Caerind

Out of interest, how does this help us? Bit beyond me - VS 2022 user

ajtruckle avatar Apr 07 '22 16:04 ajtruckle

Hi @ajtruckle !

I don't exactly know how you can add them in VS, but this link should explain it : https://docs.microsoft.com/en-us/visualstudio/debugger/create-custom-views-of-native-objects?view=vs-2022

(I'm actually using Sharpmake as a project generator and I can specify natvis directly in the project generation)

Natvis give us a better visualization of objects that can't be reprensented easily in VS debugger.

Here is an example of what I have in VS(2022, but should work with most versions I think) : image

Caerind avatar Apr 08 '22 10:04 Caerind

@Caerind there's nothing wrong with the PR, but it's more to maintain. I'm trying to keep the platform dependent "extras" out, as much as I can.

leethomason avatar Jan 15 '23 01:01 leethomason