Skip to content

Commit

Permalink
Elimination of some recently introduced compiler warnings.
Browse files Browse the repository at this point in the history
  • Loading branch information
dbukki committed Feb 29, 2024
1 parent c8f9788 commit f90aade
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions plugins/cpp/parser/src/clangastvisitor.h
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ class ClangASTVisitor : public clang::RecursiveASTVisitor<ClangASTVisitor>
// We must also make an initial scope entry for the function's body.
StatementScope ss(&_stmtStack, nullptr);
ss.MakeFunction(fd->getBody());
return Base::TraverseDecl(d_);
return Base::TraverseDecl(fd);
}
else if (clang::RecordDecl* rd = llvm::dyn_cast<clang::RecordDecl>(d_))
{
Expand All @@ -292,7 +292,7 @@ class ClangASTVisitor : public clang::RecursiveASTVisitor<ClangASTVisitor>
// The scope creates a database object for the record/type
// at the beginning, and persists it at the end.
TypeScope ts(this);
return Base::TraverseDecl(d_);
return Base::TraverseDecl(rd);
}
else return Base::TraverseDecl(d_);
}
Expand Down
2 changes: 1 addition & 1 deletion plugins/cpp_metrics/test/src/cppmetricsparsertest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
const auto v1 = val1; const auto v2 = val2; \
const bool n1 = isnan(v1); const bool n2 = isnan(v2); \
EXPECT_EQ(n1, n2); \
if (!n1 && !n2) EXPECT_NEAR(v1, v2, abs_error); \
if (!n1 && !n2) { EXPECT_NEAR(v1, v2, abs_error); } \
}

#include <model/cppfunction.h>
Expand Down

0 comments on commit f90aade

Please sign in to comment.