[clang-tools-extra] [clang-tidy] Add options to throw unannotated functions in `bugprone-exception-escape` (PR #168324)
via cfe-commits
cfe-commits at lists.llvm.org
Sun Nov 16 23:32:57 PST 2025
================
@@ -52,7 +52,7 @@ class ExceptionAnalyzer {
using Throwables = llvm::SmallDenseMap<const Type *, ThrowInfo, 2>;
static ExceptionInfo createUnknown() { return {State::Unknown}; }
- static ExceptionInfo createNonThrowing() { return {State::Throwing}; }
+ static ExceptionInfo createNonThrowing() { return {State::NotThrowing}; }
----------------
zeyi2 wrote:
I understand there are valid reasons for this function to return `Throwing`, but it still feels a bit counter-intuitive for something named `createNonThrowing` to produce a `Throwing`.
If this change doesn't match your preference, I'm totally fine reverting it. Thanks in advance.
https://github.com/llvm/llvm-project/pull/168324
More information about the cfe-commits
mailing list