Prazek added inline comments. ================ Comment at: clang-tidy/misc/ThrowWithNoexceptCheck.cpp:32 @@ +31,3 @@ +// token including trailing whitespace. +static SourceRange FindToken(const SourceManager &Sources, LangOptions LangOpts, + SourceLocation StartLoc, SourceLocation EndLoc, ---------------- function in llvm starts with lower case
================ Comment at: clang-tidy/misc/ThrowWithNoexceptCheck.cpp:57 @@ +56,3 @@ +// Returns the range of the expression including trailing whitespace. +static SourceRange ParenExprRange(const SourceManager &Sources, + LangOptions LangOpts, SourceLocation StartLoc, ---------------- same here ================ Comment at: clang-tidy/misc/ThrowWithNoexceptCheck.cpp:71 @@ +70,3 @@ + return SourceRange(); + assert(false); + } ---------------- move it one line higher ================ Comment at: clang-tidy/misc/ThrowWithNoexceptCheck.cpp:73 @@ +72,3 @@ + } + int OpenCnt = 1; + do { ---------------- Use full words. Consider changit to OpenParenCount ================ Comment at: clang-tidy/misc/ThrowWithNoexceptCheck.cpp:91 @@ +90,3 @@ + +SourceRange FindNoExceptRange(const ASTContext &Context, + const SourceManager &Sources, ---------------- rename it to findNoexceptRange at mark it static. ================ Comment at: clang-tidy/misc/ThrowWithNoexceptCheck.cpp:102 @@ +101,3 @@ + + if (!NoExceptTokenRange.isValid()) { + return SourceRange(); ---------------- remove extra braces ================ Comment at: clang-tidy/misc/ThrowWithNoexceptCheck.cpp:108-110 @@ +107,5 @@ + const auto NoexceptSpec = ProtoType->getNoexceptSpec(Context); + if (NoexceptSpec != FunctionProtoType::NR_Nothrow) { + /* We have noexcept without the expression inside */ + return SourceRange(); + } else if (ProtoType->getNoexceptExpr() == nullptr) { ---------------- The comment is wrong. Shouldn't it be // We have noexcept that doesn't evaluate to true Repository: rL LLVM http://reviews.llvm.org/D19201 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits