Menu

How to customize rules

liushuai
2022-09-22
2022-09-24
  • liushuai

    liushuai - 2022-09-22

    How to customize rules,such as:
    It is recommended to define constants using macros or const.
    The pointer variable dynamically allocated must be judged whether it is NULL before being used for the first time

     
  • Daniel Marjamäki

    in short I would suggest that you write an addon for that. That you execute with the --addon cppcheck option. For some example code you can look here:

    https://github.com/danmar/cppcheck/blob/main/addons/misc.py

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.