From: Csaba Dabis Date: Wed, 5 Jun 2019 18:55:39 +0000 (+0000) Subject: [analyzer] PathDiagnosticPopUpPiece: working with CharSourceRange X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=c1121f50f0ee8f6b9ccf804b642dddcfaa62e356;p=clang [analyzer] PathDiagnosticPopUpPiece: working with CharSourceRange Summary: Sometimes we are at character boundaries so past the token-range. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@362632 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/StaticAnalyzer/Core/HTMLDiagnostics.cpp b/lib/StaticAnalyzer/Core/HTMLDiagnostics.cpp index 8ede3f15e6..64c42699fc 100644 --- a/lib/StaticAnalyzer/Core/HTMLDiagnostics.cpp +++ b/lib/StaticAnalyzer/Core/HTMLDiagnostics.cpp @@ -612,7 +612,7 @@ HandlePopUpPieceStartTag(Rewriter &R, for (const auto &Range : PopUpRanges) { html::HighlightRange(R, Range.getBegin(), Range.getEnd(), "", "", - /*IsTokenRange=*/true); + /*IsTokenRange=*/false); } } @@ -644,12 +644,12 @@ static void HandlePopUpPieceEndTag(Rewriter &R, Out << "
"; html::HighlightRange(R, Range.getBegin(), Range.getEnd(), "", Buf.c_str(), - /*IsTokenRange=*/true); + /*IsTokenRange=*/false); // Otherwise inject just the new row at the end of the range. } else { html::HighlightRange(R, Range.getBegin(), Range.getEnd(), "", Buf.c_str(), - /*IsTokenRange=*/true); + /*IsTokenRange=*/false); } }