Microsoft C ++ Static Analysis Tool Bolsters Warning Suppressions

The Microsoft C ++ code analysis tool has been updated to provide better monitoring, justification and general management of warning suppressions. These improvements lead to a more maintainable and robust code base, according to Microsoft.

The improvements in the analysis of the Microsoft C ++ code were detailed in a July 15 Blog post. The improvements for warning suppression offer improved auditability and review, improved code maintenance, better technical debt management and coherence between suppression mechanisms, Microsoft said. With the updates of the static analysis tool, which is integrated into the Visual Studio 2022 17.14, support for gsl::suppress It has been updated to align with the last syntax of the C ++ Core guidelines. Warnings can now be suppressed using the gsl::suppress attribute.

In addition, the #pragma warning It has spread to support the justification field. Both #pragma warning(suppress) and [[gsl::suppress]] offer fine grain control over warning suppression, with #pragma warning(suppress) Be a general MSVC compiler mechanism (Microsoft Visual C ++) that can be used for any compiler warning, while [[gsl::suppress]] It will only suppress the warnings issued by the analysis of the Microsoft C ++ code. Microsoft recommends using [[gsl::suppress]] to suppress the warning warnings of Microsoft C ++ code whenever possible.

#Microsoft #Static #Analysis #Tool #Bolsters #Warning #Suppressions

Leave a Reply

Your email address will not be published. Required fields are marked *