Menu

False positive of [noConstructor] style warning

2021-05-21
2021-05-21
  • Godard Paul

    Godard Paul - 2021-05-21

    Hello,

    Cppcheck show a false positive about 'The class 'xxx' does not have a constructor although it has private member variables. [noConstructor]' style warning when using cpp 'using' keyword with same alias than the class name.

    A related issue was previously fixed (https://github.com/danmar/cppcheck/pull/3160), but was incomplete.

    You will find a PoC with details here: https://pastebin.com/4JERvmDH

    Thank you for the tool,
    Paul

     
  • Daniel Marjamäki

     

    Last edit: Daniel Marjamäki 2021-05-21

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.