[PATCH] D139926: [clangd] Add semantic token for angle brackets

Nathan Ridge via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sun Jan 29 23:45:33 PST 2023


nridge added a comment.

In D139926#4084970 <https://reviews.llvm.org/D139926#4084970>, @ckandeler wrote:

> Adding AutoTypeLoc broke tons of tests, so I left it out for now.

Poked at this a bit, it looks like `AutoTypeLoc.getLAngleLoc()` is only safe to access if it `isConstrained()`. This is poor API (it would be better to return an invalid SourceLocation rather than garbage in the `!isConstrained()` case) but for now we can check `isConstrained()` at our call site.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D139926/new/

https://reviews.llvm.org/D139926



More information about the cfe-commits mailing list