{"id":28219,"date":"2021-06-23T15:06:37","date_gmt":"2021-06-23T15:06:37","guid":{"rendered":"https:\/\/devblogs.microsoft.com\/cppblog\/?p=28219"},"modified":"2021-06-23T15:08:51","modified_gmt":"2021-06-23T15:08:51","slug":"stl-visualizers-on-github","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/cppblog\/stl-visualizers-on-github\/","title":{"rendered":"STL Visualizers on GitHub"},"content":{"rendered":"<p><span data-contrast=\"auto\">We are happy to announce that\u202fnow it\u2019s possible to contribute to the STL Visualizers for Visual Studio&#8217;s debugger on <a href=\"https:\/\/github.com\/microsoft\/STL\/blob\/main\/stl\/debugger\/STL.natvis\">GitHub<\/a>.<\/span><\/p>\n<p><span data-contrast=\"auto\">A visualizer is a file with .natvis extension that allows you to manipulate the way native types appear in the debugger&#8217;s watch window.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<p><img decoding=\"async\" class=\"aligncenter wp-image-28229\" src=\"https:\/\/devblogs.microsoft.com\/cppblog\/wp-content\/uploads\/sites\/9\/2021\/06\/watch-simpleview.png\" alt=\"A visualisation for vectors of ints\" width=\"271\" height=\"282\" \/><\/p>\n<p><span data-contrast=\"auto\">We&#8217;ve been working on fixing existing issues with the visualizers and augmenting them, but with C++20 coming with new types, they have been falling behind. We decided to open source them so that the community can benefit and collaborate.<\/span><\/p>\n<p>&nbsp;<\/p>\n<h2><span data-contrast=\"auto\">What\u2019s Available?\u00a0<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/h2>\n<p><span data-contrast=\"auto\">The file is now in the GitHub repo under <\/span><a href=\"https:\/\/github.com\/microsoft\/STL\/blob\/main\/stl\/debugger\/STL.natvis\"><span data-contrast=\"none\">stl\\debugger\\STL.natvis<\/span><\/a><span data-contrast=\"auto\">. We also have available documentation for the .natvis file format <\/span><a href=\"https:\/\/docs.microsoft.com\/en-us\/visualstudio\/debugger\/create-custom-views-of-native-objects?view=vs-2019\"><span data-contrast=\"none\">here<\/span><\/a><span data-contrast=\"auto\">.\u00a0All changes made\u00a0on\u00a0GitHub\u00a0will be ported to\u00a0Visual\u00a0Studio.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<p><span data-contrast=\"auto\">This has been up already for a couple of weeks and we are happy to see that there are already contributors helping in this new area. We would like to thank AdamBucior, statementreply, SuperWig and joemmett. Some of the PRs add visualizers to coroutines, chrono, ranges, the spaceship operator, source location, span, and more. <\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<p><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0 <\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<a href=\"https:\/\/devblogs.microsoft.com\/cppblog\/wp-content\/uploads\/sites\/9\/2021\/06\/112188892-57bd2d80-8bfb-11eb-9044-66bca3e1b2b0.png\"><img decoding=\"async\" class=\"aligncenter wp-image-28228\" src=\"https:\/\/devblogs.microsoft.com\/cppblog\/wp-content\/uploads\/sites\/9\/2021\/06\/112188892-57bd2d80-8bfb-11eb-9044-66bca3e1b2b0.png\" alt=\"Visualisation of various chrono types\" width=\"743\" height=\"368\" \/><\/a><\/span><\/p>\n<p>&nbsp;<\/p>\n<h2><span data-contrast=\"auto\">Contribute now!<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/h2>\n<p><span data-contrast=\"auto\">We are happy with the results of this change, and we would like to see more. After you make changes to the visualizer you can test them by adding the natvis file to any Visual Studio C++ project by right clicking your project, selecting Add &gt; Existing Item, and choosing the STL.natvis file. After doing this you should be able to see your changes in a Visual Studio debugging session. <\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/cppblog\/wp-content\/uploads\/sites\/9\/2021\/06\/Capture.png\"><img decoding=\"async\" class=\"aligncenter wp-image-28227\" src=\"https:\/\/devblogs.microsoft.com\/cppblog\/wp-content\/uploads\/sites\/9\/2021\/06\/Capture.png\" alt=\"Selecting the STL.natvis file\" width=\"257\" height=\"189\" \/><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>We are happy to announce that\u202fnow it\u2019s possible to contribute to the STL Visualizers for Visual Studio&#8217;s debugger on GitHub. A visualizer is a file with .natvis extension that allows you to manipulate the way native types appear in the debugger&#8217;s watch window.\u00a0 We&#8217;ve been working on fixing existing issues with the visualizers and augmenting [&hellip;]<\/p>\n","protected":false},"author":43133,"featured_media":28229,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[270,1],"tags":[],"class_list":["post-28219","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-announcement","category-cplusplus"],"acf":[],"blog_post_summary":"<p>We are happy to announce that\u202fnow it\u2019s possible to contribute to the STL Visualizers for Visual Studio&#8217;s debugger on GitHub. A visualizer is a file with .natvis extension that allows you to manipulate the way native types appear in the debugger&#8217;s watch window.\u00a0 We&#8217;ve been working on fixing existing issues with the visualizers and augmenting [&hellip;]<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/cppblog\/wp-json\/wp\/v2\/posts\/28219","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/cppblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/cppblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/cppblog\/wp-json\/wp\/v2\/users\/43133"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/cppblog\/wp-json\/wp\/v2\/comments?post=28219"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/cppblog\/wp-json\/wp\/v2\/posts\/28219\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/cppblog\/wp-json\/wp\/v2\/media\/28229"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/cppblog\/wp-json\/wp\/v2\/media?parent=28219"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/cppblog\/wp-json\/wp\/v2\/categories?post=28219"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/cppblog\/wp-json\/wp\/v2\/tags?post=28219"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}