diff options
Diffstat (limited to 'clang-tools-extra/clang-tidy/readability/DeleteNullPointerCheck.cpp')
-rw-r--r-- | clang-tools-extra/clang-tidy/readability/DeleteNullPointerCheck.cpp | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/clang-tools-extra/clang-tidy/readability/DeleteNullPointerCheck.cpp b/clang-tools-extra/clang-tidy/readability/DeleteNullPointerCheck.cpp index 72aa5ef2e3e..766dfdacb8a 100644 --- a/clang-tools-extra/clang-tidy/readability/DeleteNullPointerCheck.cpp +++ b/clang-tools-extra/clang-tidy/readability/DeleteNullPointerCheck.cpp @@ -67,16 +67,10 @@ void DeleteNullPointerCheck::check(const MatchFinder::MatchResult &Result) { *Result.SourceManager, Result.Context->getLangOpts()))); if (Compound) { - Diag << FixItHint::CreateRemoval(CharSourceRange::getTokenRange( - Compound->getLBracLoc(), - Lexer::getLocForEndOfToken(Compound->getLBracLoc(), 0, - *Result.SourceManager, - Result.Context->getLangOpts()))); - Diag << FixItHint::CreateRemoval(CharSourceRange::getTokenRange( - Compound->getRBracLoc(), - Lexer::getLocForEndOfToken(Compound->getRBracLoc(), 0, - *Result.SourceManager, - Result.Context->getLangOpts()))); + Diag << FixItHint::CreateRemoval( + CharSourceRange::getTokenRange(Compound->getLBracLoc())); + Diag << FixItHint::CreateRemoval( + CharSourceRange::getTokenRange(Compound->getRBracLoc())); } } |