We encounter a few internal reports that we're dereference a nullptr.
Unfortunately, no small reproduce testcase for this crash yet, but it makes the
clangd more robost on broken code.
Details
Details
- Reviewers
kadircet - Commits
- rG41a6085252ef: [clangd] Fix a crash in semantic highlighting.
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
clang-tools-extra/clangd/SemanticHighlighting.cpp | ||
---|---|---|
525–526 | can you add a comment here "We might have offsets in the main file that don't correspond to any spelled tokens." i think we should fix that in token buffer spelled token mappings going forward. we're relying on other places around spelledTokenAt returning a valid Token whenever we pass it a main file source location. |
can you add a comment here "We might have offsets in the main file that don't correspond to any spelled tokens." i think we should fix that in token buffer spelled token mappings going forward. we're relying on other places around spelledTokenAt returning a valid Token whenever we pass it a main file source location.