Author: Kazu Hirata Date: 2023-11-16T11:06:01-08:00 New Revision: f8e8530f7377ab84b23c268454015fbcb95231c0
URL: https://github.com/llvm/llvm-project/commit/f8e8530f7377ab84b23c268454015fbcb95231c0 DIFF: https://github.com/llvm/llvm-project/commit/f8e8530f7377ab84b23c268454015fbcb95231c0.diff LOG: [StaticAnalyzer] Fix warnings about missing override This patch fixes: clang/lib/StaticAnalyzer/Checkers/StdLibraryFunctionsChecker.cpp:609:23: error: 'describe' overrides a member function but is not marked 'override' [-Werror,-Winconsistent-missing-override] clang/lib/StaticAnalyzer/Checkers/StdLibraryFunctionsChecker.cpp:627:23: error: 'describe' overrides a member function but is not marked 'override' [-Werror,-Winconsistent-missing-override] Added: Modified: clang/lib/StaticAnalyzer/Checkers/StdLibraryFunctionsChecker.cpp Removed: ################################################################################ diff --git a/clang/lib/StaticAnalyzer/Checkers/StdLibraryFunctionsChecker.cpp b/clang/lib/StaticAnalyzer/Checkers/StdLibraryFunctionsChecker.cpp index 2163689c6a05906..fffcaf7ed18fb7c 100644 --- a/clang/lib/StaticAnalyzer/Checkers/StdLibraryFunctionsChecker.cpp +++ b/clang/lib/StaticAnalyzer/Checkers/StdLibraryFunctionsChecker.cpp @@ -606,7 +606,7 @@ class StdLibraryFunctionsChecker return errno_modeling::setErrnoForStdSuccess(State, C); } - const std::string describe(CheckerContext &C) const { + const std::string describe(CheckerContext &C) const override { return "'errno' becomes undefined after the call"; } }; @@ -624,7 +624,7 @@ class StdLibraryFunctionsChecker Call.getOriginExpr()); } - const std::string describe(CheckerContext &C) const { + const std::string describe(CheckerContext &C) const override { return "reading 'errno' is required to find out if the call has failed"; } }; _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits