[clangd] Force delayed-template-parsing off in code completion.
authorSam McCall <sam.mccall@gmail.com>
Tue, 31 Mar 2020 21:33:56 +0000 (23:33 +0200)
committerSam McCall <sam.mccall@gmail.com>
Wed, 1 Apr 2020 09:09:15 +0000 (11:09 +0200)
commit038f03cb5ef5d44676cbde06560ed2668f4a7acc
tree62da0cbe1cbbddd94442ea58cbf5aa57a07a5144
parentd307174e1d9e66a9e5a1e936ac3736343c3fe381
[clangd] Force delayed-template-parsing off in code completion.

Summary:
It prevents code completion entirely in affected method bodies.
The main reason it's turned on is for compatibility with headers, so we turn it
off for the main file only. This is allowed because it's a compatible langopt.

Fixes https://github.com/clangd/clangd/issues/302

Reviewers: kadircet

Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, usaxena95, cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D77176
clang-tools-extra/clangd/CodeComplete.cpp
clang-tools-extra/clangd/unittests/CodeCompleteTests.cpp