{"id":4628,"date":"2025-12-05T16:32:21","date_gmt":"2025-12-05T20:32:21","guid":{"rendered":"https:\/\/www.wholetomato.com\/blog\/?p=4628"},"modified":"2025-12-08T11:14:41","modified_gmt":"2025-12-08T15:14:41","slug":"writing-safer-c-introducing-visual-assists-new-code-safety-inspections","status":"publish","type":"post","link":"https:\/\/www.wholetomato.com\/blog\/writing-safer-c-introducing-visual-assists-new-code-safety-inspections\/","title":{"rendered":"Writing Safer C++: Introducing Visual Assist\u2019s New Code Safety Inspections"},"content":{"rendered":"<p><span style=\"font-weight: 400;\">C++ Safety is one of the most important conversations happening in software right now. From industry leaders to government agencies, including recent guidance coming from the U.S. government, there is a renewed call to strengthen memory safety and reduce classes of bugs that have historically plagued C and C++ projects.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">But here is the reality: C++ remains one of the most critical languages in the world. Operating systems, embedded systems, real time control software, game engines, medical devices, aerospace systems, these all rely on C++ for its power, determinism, and performance. Rewriting the world in another language is unrealistic.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Instead, we need tools that help developers write safer C++ today.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">With that goal in mind, the latest <a href=\"https:\/\/www.wholetomato.com\/blog\/visual-assist-2025-4-release-post\/\">release<\/a> of Visual Assist introduces a major new capability: C++ Safety Code Inspections, designed to surface correctness issues, prevent subtle runtime failures, and reinforce best practices drawn from CERT, the C++ Core Guidelines, and modern safety literature.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">This post will guide you through how to enable the new feature, what categories of checkers are included, and what kinds of issues these inspections can help you catch before they reach production.<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">Enabling C++ Safety Code Inspections<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">Getting started takes just a few seconds. In Visual Studio:<\/span><\/p>\n<ol>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Go to Extensions &#8211; VAssistX &#8211; Visual Assist Options<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Open the Code Inspections section<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Enable Enable Code Inspections<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Choose one of the inspection sets:<\/span>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><b>VA Default<\/b><span style=\"font-weight: 400;\">, the standard Visual Assist inspections<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><b>C++ Safety<\/b><span style=\"font-weight: 400;\">, only the safety focused checkers<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><b>Combined (Recommended)<\/b><span style=\"font-weight: 400;\">, the full suite of VA Default plus C++ Safety<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<p><span style=\"font-weight: 400;\">We recommend Combined, since it brings together the long trusted VA inspections with the new safety focused rules for the strongest possible coverage.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">You will also see a list of all <a href=\"https:\/\/www.wholetomato.com\/en\/documentation\/code-inspection\/list-of-code-inspections\">checkers<\/a> included in the selected set, and that is where the real power begins.<\/span><\/p>\n<p><a href=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Options-Menu.png?ssl=1\"><img loading=\"lazy\" decoding=\"async\" data-attachment-id=\"4629\" data-permalink=\"https:\/\/www.wholetomato.com\/blog\/writing-safer-c-introducing-visual-assists-new-code-safety-inspections\/code-inspection-options-menu\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Options-Menu.png?fit=1564%2C1188&amp;ssl=1\" data-orig-size=\"1564,1188\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"Code Inspection Options Menu\" data-image-description=\"&lt;p&gt;Enabling C++ Safety Code Inspections in Visual Assist takes only seconds inside Visual Studio.&lt;\/p&gt;\n\" data-image-caption=\"\" data-medium-file=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Options-Menu.png?fit=300%2C228&amp;ssl=1\" data-large-file=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Options-Menu.png?fit=1024%2C778&amp;ssl=1\" class=\"alignnone wp-image-4629\" src=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Options-Menu.png?resize=658%2C500&#038;ssl=1\" alt=\"\" width=\"658\" height=\"500\" srcset=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Options-Menu.png?resize=1024%2C778&amp;ssl=1 1024w, https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Options-Menu.png?resize=300%2C228&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Options-Menu.png?resize=768%2C583&amp;ssl=1 768w, https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Options-Menu.png?resize=1536%2C1167&amp;ssl=1 1536w, https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Options-Menu.png?resize=360%2C273&amp;ssl=1 360w, https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Options-Menu.png?w=1564&amp;ssl=1 1564w\" sizes=\"auto, (max-width: 658px) 100vw, 658px\" data-recalc-dims=\"1\" \/><\/a><\/p>\n<h2><span style=\"font-weight: 400;\">Understanding the New C++ Safety Checkers<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">The new feature groups inspections into thematic categories that address correctness, memory safety, undefined behavior, modern C++ best practices, and more. Here is a quick overview of what each category brings to your workflow:<\/span><\/p>\n<h3><span style=\"font-weight: 400;\">1. Core Analysis<\/span><\/h3>\n<p><span style=\"font-weight: 400;\">Catches the fundamental safety hazards in C++:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Null dereferences<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Division by zero<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Uninitialized variables<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Undefined arithmetic or operator behavior<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">These are the kinds of bugs that turn into intermittent crashes, the worst kind to debug.<\/span><\/p>\n<h3><span style=\"font-weight: 400;\">2. C++ Specific Issues<\/span><\/h3>\n<p><span style=\"font-weight: 400;\">Monitors dangerous or incorrect use of core language features:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Mismatched new and delete<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Incorrect move semantics<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Leaking or dangling inner pointers<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Calling pure virtual functions in constructors<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">These checkers help prevent the subtle, low level mistakes that can undermine an otherwise correct system.<\/span><\/p>\n<h3><span style=\"font-weight: 400;\">3. Nullability<\/span><\/h3>\n<p><span style=\"font-weight: 400;\">Helps enforce contracts about pointer lifetimes and expectations:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Passing null to functions that forbid it<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Returning null from a function marked as non null<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Dereferencing potentially null pointers<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">This gives you stronger guarantees across API boundaries.<\/span><\/p>\n<h3><span style=\"font-weight: 400;\">4. CERT Standards<\/span><\/h3>\n<p><span style=\"font-weight: 400;\">Implements widely respected secure coding rules:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">ERR33 C (Detecting runtime errors)<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">ERR58 CPP (Handling logic errors)<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">MSC50 and MSC51 (Avoiding undefined behavior)<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">DCL54 and OOP54 safety rules<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">Ideal for industries that require compliance or audits.<\/span><\/p>\n<h3><span style=\"font-weight: 400;\">5. C++ Core Guidelines<\/span><\/h3>\n<p><span style=\"font-weight: 400;\">Reinforces modern best practices:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Avoiding C style arrays<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Preventing narrowing conversions<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Correct ownership and memory models<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Ensuring proper initialization and noexcept guarantees<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">A great toolkit for teams modernizing a legacy codebase.<\/span><\/p>\n<h3><span style=\"font-weight: 400;\">6. Bug Prevention<\/span><\/h3>\n<p><span style=\"font-weight: 400;\">Targets patterns known to hide serious defects:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Use after move<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Misplaced pointer arithmetic during allocation<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Dangerous memcpy, memset, and realloc usage<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Comparing memory incorrectly<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Smart pointer array mismatches<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">These are among the highest value checkers for catching issues early.<\/span><\/p>\n<h3><span style=\"font-weight: 400;\">7. Modernization and Performance<\/span><\/h3>\n<p><span style=\"font-weight: 400;\">Promotes cleaner, faster, more idiomatic code:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Prefer nullptr<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Use equals default where appropriate<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Recommend default member initializers<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Identify functions that should be noexcept<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">A cleaner codebase is almost always a safer codebase.<\/span><\/p>\n<h3><span style=\"font-weight: 400;\">8. Concurrency<\/span><\/h3>\n<p><span style=\"font-weight: 400;\">Surfaces potentially unsafe multi threaded operations.<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">What Do These Inspections Catch in Practice?<\/span><\/h2>\n<h3><span style=\"font-weight: 400;\">Example 1: Use After Move<\/span><\/h3>\n<div class=\"wp-block-codemirror-blocks code-block\">\n<pre class=\"CodeMirror\" data-setting=\"{&quot;mode&quot;:&quot;clike&quot;,&quot;mime&quot;:&quot;text\/x-c++src&quot;,&quot;theme&quot;:&quot;duotone-dark&quot;,&quot;lineNumbers&quot;:false,&quot;lineWrapping&quot;:false,&quot;styleActiveLine&quot;:false,&quot;readOnly&quot;:true,&quot;align&quot;:&quot;&quot;}\">std::string s = \"Hello\";\r\n\r\nstd::string t = std::move(s);\r\n\r\n\r\n\/\/ ...\r\n\r\nif (s.size() &gt; 0) { \/* undefined behavior *\/ }<\/pre>\n<\/div>\n<p><span style=\"font-weight: 400;\">After s is moved from, it should not be accessed. The checker flags this immediately, long before it becomes a nondeterministic crash in production.<\/span><\/p>\n<p><a href=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-After-Move.png?ssl=1\"><img loading=\"lazy\" decoding=\"async\" data-attachment-id=\"4630\" data-permalink=\"https:\/\/www.wholetomato.com\/blog\/writing-safer-c-introducing-visual-assists-new-code-safety-inspections\/code-inspection-example-after-move\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-After-Move.png?fit=845%2C328&amp;ssl=1\" data-orig-size=\"845,328\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"Code Inspection Example &#8211; After Move\" data-image-description=\"&lt;p&gt;Visual Assist flags use-after-move errors before they reach runtime.&lt;\/p&gt;\n\" data-image-caption=\"\" data-medium-file=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-After-Move.png?fit=300%2C116&amp;ssl=1\" data-large-file=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-After-Move.png?fit=845%2C328&amp;ssl=1\" class=\"alignnone wp-image-4630\" src=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-After-Move.png?resize=755%2C293&#038;ssl=1\" alt=\"\" width=\"755\" height=\"293\" srcset=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-After-Move.png?w=845&amp;ssl=1 845w, https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-After-Move.png?resize=300%2C116&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-After-Move.png?resize=768%2C298&amp;ssl=1 768w, https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-After-Move.png?resize=360%2C140&amp;ssl=1 360w\" sizes=\"auto, (max-width: 755px) 100vw, 755px\" data-recalc-dims=\"1\" \/><\/a><\/p>\n<h3><span style=\"font-weight: 400;\">Example 2: Null Dereference<\/span><\/h3>\n<div class=\"wp-block-codemirror-blocks code-block \">\n<pre class=\"CodeMirror\" data-setting=\"{&quot;mode&quot;:&quot;clike&quot;,&quot;mime&quot;:&quot;text\/x-c++src&quot;,&quot;theme&quot;:&quot;duotone-dark&quot;,&quot;lineNumbers&quot;:false,&quot;lineWrapping&quot;:false,&quot;styleActiveLine&quot;:false,&quot;readOnly&quot;:true,&quot;align&quot;:&quot;&quot;}\">class Widget\r\n{\r\npublic:\r\n\tint value;\r\n};\r\n\r\nint main()\r\n{\r\n\tWidget* w = 0;      \r\n\tint v = w-&gt;value;   \/\/ NullDereference\r\n\r\n\treturn v;\r\n}\r\n<\/pre>\n<\/div>\n<p><span style=\"font-weight: 400;\">Even in simple code, a null pointer dereference can lead to an immediate crash. In this example, w is null and the code still attempts to access w-&gt;value(). The C++ Safety inspections in Visual Assist detect this pattern instantly and warn you before the program ever runs.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">These are exactly the kinds of issues that safety standards and auditors focus on, because they can cause unpredictable behavior or runtime failures. Visual Assist now helps you catch them early, making your C++ code safer and more robust by default.<\/span><\/p>\n<p><a href=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-Null-Dereference.png?ssl=1\"><img loading=\"lazy\" decoding=\"async\" data-attachment-id=\"4634\" data-permalink=\"https:\/\/www.wholetomato.com\/blog\/writing-safer-c-introducing-visual-assists-new-code-safety-inspections\/code-inspection-example-null-dereference\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-Null-Dereference.png?fit=1322%2C467&amp;ssl=1\" data-orig-size=\"1322,467\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"Code Inspection Example- Null Dereference\" data-image-description=\"&lt;p&gt;Null pointer dereferences are detected instantly through the new C++ Safety inspections.&lt;\/p&gt;\n\" data-image-caption=\"\" data-medium-file=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-Null-Dereference.png?fit=300%2C106&amp;ssl=1\" data-large-file=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-Null-Dereference.png?fit=1024%2C362&amp;ssl=1\" class=\"alignnone wp-image-4634\" src=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-Null-Dereference.png?resize=733%2C259&#038;ssl=1\" alt=\"\" width=\"733\" height=\"259\" srcset=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-Null-Dereference.png?resize=1024%2C362&amp;ssl=1 1024w, https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-Null-Dereference.png?resize=300%2C106&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-Null-Dereference.png?resize=768%2C271&amp;ssl=1 768w, https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-Null-Dereference.png?resize=360%2C127&amp;ssl=1 360w, https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/Code-Inspection-Example-Null-Dereference.png?w=1322&amp;ssl=1 1322w\" sizes=\"auto, (max-width: 733px) 100vw, 733px\" data-recalc-dims=\"1\" \/><\/a><\/p>\n<h2><span style=\"font-weight: 400;\">Why This Matters for Modern C++<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">For teams working on embedded systems, real time applications, or any scenario where failure is not an option, safety tooling is becoming non negotiable. Even outside regulated industries, memory safety issues are expensive: crashes, CVEs, customer escalations, and time lost debugging.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Visual Assist\u2019s new C++ Safety inspections provide:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Early detection of correctness issues<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Guidance toward modern, maintainable C++<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Support for CERT and C++ Core Guidelines<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Protection against undefined behavior and memory hazards<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Higher confidence in legacy and safety critical systems<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">C++ is not going away, and with the right tooling, it does not need to.<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">Conclusion: Safer C++ with Visual Assist<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">Whether you are maintaining a large legacy codebase, building safety critical software, or simply want tighter correctness guarantees, the new C++ Safety Code Inspections in Visual Assist bring modern static analysis directly into your everyday workflow.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">By combining industry standards, smart analysis, and deep C++ knowledge, Visual Assist helps you write code that is not only fast and expressive, but also safe.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Enable the inspections, choose the Combined profile, and let Visual Assist guide you toward more robust, reliable C++ development.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Your code and your users will thank you.<\/span><\/p>\n<div class=\"extended-banner\">\r\n\t<img decoding=\"async\" class=\"img\" src=\"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/05\/wtlogo25.png?w=1140&#038;ssl=1\" data-recalc-dims=\"1\" \/>\r\n\t<h2 class=\"title\">VA Code Inspections: Automatically detect and fix code smells.<\/h2>\r\n\t<div class=\"actions\">\r\n\t\t<a href=\"https:\/\/www.wholetomato.com\/downloads?utm_content=blog-\" class=\"button primary\">Try Visual Assist<\/a>\r\n\t\t<a href=\"https:\/\/www.wholetomato.com\/en\/features\/feature-code-inspection?utm_content=blog-\" class=\"button secondary\">Learn More<\/a>\r\n\t<\/div>\r\n<\/div>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>C++ Safety is one of the most important conversations happening in software right now. From industry leaders to government agencies, including recent guidance coming from the U.S. government, there is a renewed call to strengthen&#8230;<\/p>\n","protected":false},"author":213500358,"featured_media":4639,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_coblocks_attr":"","_coblocks_dimensions":"","_coblocks_responsive_height":"","_coblocks_accordion_ie_support":"","jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_newsletter_tier_id":0,"footnotes":"","jetpack_publicize_message":"","jetpack_is_tweetstorm":false,"jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false}}},"categories":[103,672],"tags":[726360548,726360503,726360529,726360521,726360513,726360542,726360550,726360544,726360546,12004844],"class_list":["post-4628","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-news","category-tips-and-tricks","tag-c-bug-prevention","tag-c-code-inspections","tag-c-core-guidelines","tag-c-safety","tag-c-static-analysis","tag-cert-c-guidelines","tag-legacy-c-modernization","tag-memory-safety-c","tag-undefined-behavior-c","tag-visual-assist"],"jetpack_publicize_connections":[],"aioseo_notices":[],"jetpack_featured_media_url":"https:\/\/i0.wp.com\/www.wholetomato.com\/blog\/wp-content\/uploads\/2025\/12\/imagem-1.png?fit=1320%2C600&ssl=1","jetpack_likes_enabled":true,"jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/pfpLS4-1cE","amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.wholetomato.com\/blog\/wp-json\/wp\/v2\/posts\/4628","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wholetomato.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wholetomato.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wholetomato.com\/blog\/wp-json\/wp\/v2\/users\/213500358"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wholetomato.com\/blog\/wp-json\/wp\/v2\/comments?post=4628"}],"version-history":[{"count":6,"href":"https:\/\/www.wholetomato.com\/blog\/wp-json\/wp\/v2\/posts\/4628\/revisions"}],"predecessor-version":[{"id":4638,"href":"https:\/\/www.wholetomato.com\/blog\/wp-json\/wp\/v2\/posts\/4628\/revisions\/4638"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.wholetomato.com\/blog\/wp-json\/wp\/v2\/media\/4639"}],"wp:attachment":[{"href":"https:\/\/www.wholetomato.com\/blog\/wp-json\/wp\/v2\/media?parent=4628"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wholetomato.com\/blog\/wp-json\/wp\/v2\/categories?post=4628"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wholetomato.com\/blog\/wp-json\/wp\/v2\/tags?post=4628"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}