File tree Expand file tree Collapse file tree 1 file changed +10
-11
lines changed
Expand file tree Collapse file tree 1 file changed +10
-11
lines changed Original file line number Diff line number Diff line change @@ -24,19 +24,18 @@ void MemberNamesCheck::registerMatchers(MatchFinder *Finder) {
2424
2525void MemberNamesCheck::check (const MatchFinder::MatchResult &Result) {
2626 const auto *MatchedDecl = Result.Nodes .getNodeAs <FieldDecl>(" field_decl1" );
27- if (MatchedDecl)
28- {
29- // check that we are inside the AliceO2 namespace to exlude system stuff
30- if ( MatchedDecl->getQualifiedNameAsString ().find (" AliceO2::" ) == std::string::npos )
31- return ;
27+ if (MatchedDecl) {
28+ // check that we are inside the AliceO2 namespace to exlude system stuff
29+ if ( MatchedDecl->getQualifiedNameAsString ().find (" AliceO2::" ) != 0 )
30+ return ;
3231
33- if (MatchedDecl->getName ().startswith (" m" )){
34- return ;
35- }
36- diag (MatchedDecl->getLocation (), " field declaration %0 does not match naming rule" , DiagnosticIDs::Error)
37- << MatchedDecl;
38- // << FixItHint::CreateInsertion(MatchedDecl->getLocation(), "f");
32+ if (MatchedDecl->getName ().startswith (" m" )){
33+ return ;
3934 }
35+ diag (MatchedDecl->getLocation (), " field declaration %0 does not match naming rule" , DiagnosticIDs::Error)
36+ << MatchedDecl;
37+ // << FixItHint::CreateInsertion(MatchedDecl->getLocation(), "f");
38+ }
4039}
4140
4241} // namespace aliceO2
You can’t perform that action at this time.
0 commit comments