llvm-project/clang-tools-extra
Sam McCall 33c3ef2fbe [CodeCompletion][clangd] Clean __uglified parameter names in completion & hover
Underscore-uglified identifiers are used in standard library implementations to
guard against collisions with macros, and they hurt readability considerably.
(Consider `push_back(Tp_ &&__value)` vs `push_back(Tp value)`.
When we're describing an interface, the exact names of parameters are not
critical so we can drop these prefixes.

This patch adds a new PrintingPolicy flag that can applies this stripping
when recursively printing pieces of AST.
We set it in code completion/signature help, and in clangd's hover display.
All three features also do a bit of manual poking at names, so fix up those too.

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

Differential Revision: https://reviews.llvm.org/D116387
2022-01-26 15:51:17 +01:00
..
clang-apply-replacements [clang-apply-replacements] Correctly handle relative paths 2021-11-11 18:28:43 +00:00
clang-change-namespace Reapply "Support Attr in DynTypedNode and ASTMatchers." 2021-08-06 22:30:32 +02:00
clang-doc [clang-tools-extra][cmake] Use `GNUInstallDirs` to support custom installation dirs. 2022-01-22 20:57:21 +00:00
clang-include-fixer [clang-tools-extra][cmake] Use `GNUInstallDirs` to support custom installation dirs. 2022-01-22 20:57:21 +00:00
clang-move [SystemZ][z/OS][Windows] Add new OF_TextWithCRLF flag and use this flag instead of OF_Text 2021-04-06 07:23:31 -04:00
clang-query [clang-query] Add check to prevent setting srcloc when no introspection is available. 2021-04-28 11:21:35 +01:00
clang-reorder-fields [clang-tooling] Prevent llvm::fatal_error on invalid CLI option 2021-01-29 10:15:06 +01:00
clang-tidy Rewrite Doxygen comment to resolve -Wdocumentation warning (NFC) 2022-01-27 02:21:05 +13:00
clangd [CodeCompletion][clangd] Clean __uglified parameter names in completion & hover 2022-01-26 15:51:17 +01:00
docs [clang-tidy] [bugprone-assert-side-effect] Ignore list for functions/methods 2022-01-25 21:04:07 +03:00
modularize [clang-tools-extra][cmake] Use `GNUInstallDirs` to support custom installation dirs. 2022-01-22 20:57:21 +00:00
pp-trace [clang] Let PPCallbacks::PragmaWarning() pass specifier as enum instead of string 2021-09-28 19:47:27 -04:00
test Re-land "Cache the locations of NOLINTBEGIN/END blocks" with fix for build bot 2022-01-27 01:03:27 +13:00
tool-template [OpenMP] "UnFix" layering problem with FrontendOpenMP 2020-04-07 14:41:18 -05:00
unittests [clang-tidy][NFC] Move CachedGlobList to GlobList.h 2021-12-04 08:50:49 +00:00
.gitignore
CMakeLists.txt [clang-tools-extra][cmake] Use `GNUInstallDirs` to support custom installation dirs. 2022-01-22 20:57:21 +00:00
CODE_OWNERS.TXT
LICENSE.TXT
README.txt

README.txt

//===----------------------------------------------------------------------===//
// Clang Tools repository
//===----------------------------------------------------------------------===//

Welcome to the repository of extra Clang Tools.  This repository holds tools
that are developed as part of the LLVM compiler infrastructure project and the
Clang frontend.  These tools are kept in a separate "extra" repository to
allow lighter weight checkouts of the core Clang codebase.

This repository is only intended to be checked out inside of a full LLVM+Clang
tree, and in the 'tools/extra' subdirectory of the Clang checkout.

All discussion regarding Clang, Clang-based tools, and code in this repository
should be held using the standard Clang mailing lists:
  http://lists.llvm.org/mailman/listinfo/cfe-dev

Code review for this tree should take place on the standard Clang patch and
commit lists:
  http://lists.llvm.org/mailman/listinfo/cfe-commits

If you find a bug in these tools, please file it in the LLVM bug tracker:
  http://llvm.org/bugs/