HomePhabricator

[clangd] Send empty diagnostics when a file is closed

Authored by ilya-biryukov on Mar 25 2019, 3:15 AM.

Description

[clangd] Send empty diagnostics when a file is closed

Summary:
The LSP clients cannot know clangd will not send diagnostic updates
for closed files, so we send them an empty list of diagnostics to
avoid showing stale diagnostics for closed files in the UI, e.g. in the
"Problems" pane of VSCode.

Fixes PR41217.

Reviewers: hokein

Reviewed By: hokein

Subscribers: ioeric, MaskRay, jkorous, arphaman, kadircet, cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D59757

llvm-svn: 356880

Details

Committed
ilya-biryukovMar 25 2019, 3:15 AM
Reviewer
hokein
Differential Revision
D59757: [clangd] Send empty diagnostics when a file is closed
Parents
rGa5a4bb69c16f: Add llvm:: qualifer to make_unique, NFC
Branches
Unknown
Tags
Unknown