[clang] [clang][ThreadSafety] Warn when constructor is trylock (PR #95290)

Aaron Ballman via cfe-commits cfe-commits at lists.llvm.org
Mon Jun 17 06:47:17 PDT 2024


AaronBallman wrote:

> @AaronBallman, please take a look!
> 
> What do you think of this approach? I suppose it might be even better to enforce that the function's return type is `bool`, which would align with the [ThreadSafetyAnalysis documentation](https://clang.llvm.org/docs/ThreadSafetyAnalysis.html#try-acquire-bool-try-acquire-shared-bool).

Oops, I missed this comment -- it seems we had similar lines of thought. :-)

https://github.com/llvm/llvm-project/pull/95290


More information about the cfe-commits mailing list