[cfe-dev] [analyzer] introducing exceptions checkers
Kirill Bobyrev via cfe-dev
cfe-dev at lists.llvm.org
Sun Sep 6 13:46:29 PDT 2015
Yes, I totally missed it. Thanks for pointing it out! I'll fix that
soon. As well as adding the third checker
(/exceptions.ThrownTypeDiffersSpec/) into the "master" one.
On 9/6/2015 11:42 PM, Gábor Horváth wrote:
> Thank you for working on the static analyzer! I have one high level
> comment though. The noexcept or throw() does not mean that a function
> can not contain a throw expression. It means that an exception can not
> leak out from that function. So it is perfectly valid to throw an
> exception and catch it (without rethrowing it) within a noexcept
> function. This is something that you might want to consider (in a
> future version).
> On 6 September 2015 at 22:08, Kirill Bobyrev via cfe-dev
> <cfe-dev at lists.llvm.org <mailto:cfe-dev at lists.llvm.org>> wrote:
> I've done the initial version of exceptions checkers from the
> potential checkers list
> <http://clang-analyzer.llvm.org/potential_checkers.html>. I
> actually found /exceptions.ThrowSpecButNotThrow/ and
> /exceptions.NoThrowSpecButThrows/ very similar and decided to put
> them together into /exceptions.ExceptionSpec/. It checks for
> "throw calls" in functions specified as noexcept and functions,
> which do not have "throw calls" but should have such calls inside
> them by declaration.
> The first version of checker is attached. I wonder if it's good
> enough and I can push it for the review.
> Feedback and suggestions highly appreciated!
> Kirill Bobyrev
> cfe-dev mailing list
> cfe-dev at lists.llvm.org <mailto:cfe-dev at lists.llvm.org>
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the cfe-dev