Skip to content

CPP_WARN_INCONSISTENT_MISSING_OVERRIDE: Clang warning stopped working #71

@RobbyCBennett

Description

@RobbyCBennett

I made a bug in our code because my derived class re-declared non-virtual functions in a base class. Specifically, these were Qt signal functions.

This warning -Winconsistent-missing-override is enabled by default, so I would expect the following code to have a warning in clang++.

class Base {
  void f();
};

class Derived: public Base {
  void f(); // UndCC_Violation
};

It would be cool if we had tests for all of our CodeChecks. That's probably not a realistic goal.

Metadata

Metadata

Labels

No labels
No labels

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions