[clangd] Show non-instantiated decls in signatureHelp
authorIlya Biryukov <ibiryukov@google.com>
Tue, 14 Aug 2018 09:36:32 +0000 (09:36 +0000)
committerIlya Biryukov <ibiryukov@google.com>
Tue, 14 Aug 2018 09:36:32 +0000 (09:36 +0000)
commit8fd44bb915cc62615240c8b8fde2e5fb3f3e2d82
tree95f0431e0d1a3cb8355a5c54ee9a541bcbc22236
parent661cc1e104f3c8b174721497e35f12e95a52774f
[clangd] Show non-instantiated decls in signatureHelp

Summary:
To avoid producing very verbose output in substitutions involving
typedefs, e.g.
  T -> std::vector<std::string>::iterator
gets turned into an unreadable mess when printed out for libstdc++,
result contains internal types (std::__Vector_iterator<...>) and
expanded well-defined typedefs (std::basic_string<char>).

Until we improve the presentation code in clang, going with
non-instantiated decls looks like a better UX trade-off.

Reviewers: hokein, ioeric, kadircet

Reviewed By: hokein

Subscribers: MaskRay, jkorous, arphaman, cfe-commits

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

llvm-svn: 339665
clang-tools-extra/clangd/CodeComplete.cpp
clang-tools-extra/unittests/clangd/CodeCompleteTests.cpp