[cfe-commits] r96161 - /cfe/trunk/tools/CIndex/CIndex.cpp
Douglas Gregor
dgregor at apple.com
Mon Feb 15 08:48:51 PST 2010
On Feb 14, 2010, at 2:02 AM, Daniel Dunbar wrote:
> Author: ddunbar
> Date: Sun Feb 14 04:02:42 2010
> New Revision: 96161
>
> URL: http://llvm.org/viewvc/llvm-project?rev=96161&view=rev
> Log:
> CIndex: Avoid an unnecessary getLocForEndOfToken call, the region of interest
> doesn't need to be a full token.
> - Doug, please review.
>
> Modified:
> cfe/trunk/tools/CIndex/CIndex.cpp
>
> Modified: cfe/trunk/tools/CIndex/CIndex.cpp
> URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/tools/CIndex/CIndex.cpp?rev=96161&r1=96160&r2=96161&view=diff
>
> ==============================================================================
> --- cfe/trunk/tools/CIndex/CIndex.cpp (original)
> +++ cfe/trunk/tools/CIndex/CIndex.cpp Sun Feb 14 04:02:42 2010
> @@ -1468,8 +1468,7 @@
> SourceLocation SLoc = cxloc::translateSourceLocation(Loc);
> CXCursor Result = MakeCXCursorInvalid(CXCursor_NoDeclFound);
> if (SLoc.isValid()) {
> - SourceRange RegionOfInterest(SLoc,
> - CXXUnit->getPreprocessor().getLocForEndOfToken(SLoc, 1));
> + SourceRange RegionOfInterest(SLoc, SLoc);
Yes, this is fine. Thanks!
- Doug
More information about the cfe-commits
mailing list