[PATCH] D19201: [clang-tidy] misc-throw-with-noexcept

Stanisław Barzowski via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Mar 6 12:49:53 PST 2017


sbarzowski added inline comments.


================
Comment at: clang-tidy/misc/ThrowWithNoexceptCheck.h:20
+///\brief Warns about using throw in function declared as noexcept.
+/// It complains about every throw, even if it is caught later.
+class ThrowWithNoexceptCheck : public ClangTidyCheck {
----------------
vmiklos wrote:
> Prazek wrote:
> > aaron.ballman wrote:
> > > What is the false positive rate with this check over a large codebase that uses exceptions?
> > Do you know any good project to check it?
> LibreOffice might be a candidate, see <https://wiki.documentfoundation.org/Development/ClangTidy> for details on how to generate a compile database for it (since it does not use cmake), then you can start testing.
Thanks. However it's not just about using exception. To be meaningful I need a project that use noexcept in more than a few places.

Here are some projects that I found:
https://github.com/facebook/hhvm/search?utf8=%E2%9C%93&q=noexcept
https://github.com/facebook/folly/search?utf8=%E2%9C%93&q=noexcept
https://github.com/Tencent/mars/search?utf8=%E2%9C%93&q=noexcept
https://github.com/facebook/rocksdb/search?utf8=%E2%9C%93&q=noexcept
https://github.com/CRYTEK-CRYENGINE/CRYENGINE/search?utf8=%E2%9C%93&q=noexcept
https://github.com/SFTtech/openage/search?utf8=%E2%9C%93&q=noexcept
https://github.com/facebook/watchman/search?utf8=%E2%9C%93&q=noexcept
https://github.com/facebook/proxygen/search?utf8=%E2%9C%93&q=noexcept
https://github.com/philsquared/Catch/search?utf8=%E2%9C%93&q=noexcept
https://github.com/sandstorm-io/capnproto/search?utf8=%E2%9C%93&q=noexcept
https://github.com/miloyip/rapidjson/search?utf8=%E2%9C%93&q=noexcept

I've tried HHVM so far, and ran into some problems compiling it. Anyway I'm working on it.


https://reviews.llvm.org/D19201





More information about the cfe-commits mailing list