erikjv added inline comments.

================
Comment at: lib/Sema/SemaExpr.cpp:2061-2062
+  auto Builder = Diag(R.getNameLoc(), diagnostic) << Name;
+  if (Name.isIdentifier())
+    Builder << SourceRange(R.getNameLoc());
   return true;
----------------
rsmith wrote:
> I'm indifferent on this change: I don't see much point in adding a 
> single-token range when we already point the caret at that token, but I don't 
> see any harm either.
It's mostly about how much is "underlined". If there is only a caret, that 
quite often translates into a single character being pointed out, instead of an 
identifier (i.e. the first character). Hene the extension of the range.


https://reviews.llvm.org/D21075



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to