HomePhabricator

[clangd] Suggest adding missing includes for incomplete type diagnostics.

Description

[clangd] Suggest adding missing includes for incomplete type diagnostics.

Summary:
This enables clangd to intercept compiler diagnostics and attach fixes (e.g. by
querying index). This patch adds missing includes for incomplete types e.g.
member access into class with only forward declaration. This would allow adding
missing includes for user-typed symbol names that are missing declarations
(e.g. typos) in the future.

Reviewers: sammccall

Reviewed By: sammccall

Subscribers: mgorny, ilya-biryukov, javed.absar, MaskRay, jkorous, mgrang, arphaman, kadircet, cfe-commits

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

Details

Committed
ioericJan 28 2019, 6:01 AM
Reviewer
sammccall
Differential Revision
D56903: [clangd] Suggest adding missing includes for incomplete type diagnostics.
Branches
Unknown
Tags
Unknown