Extra Clang Tools 5 documentation

clang-tidy - readability-redundant-member-init

«  readability-redundant-function-ptr-dereference   ::   Contents   ::   readability-redundant-smartptr-get  »

readability-redundant-member-init

Finds member initializations that are unnecessary because the same default constructor would be called if they were not present.

Example:

// Explicitly initializing the member s is unnecessary.
class Foo {
public:
  Foo() : s() {}

private:
  std::string s;
};

«  readability-redundant-function-ptr-dereference   ::   Contents   ::   readability-redundant-smartptr-get  »