llvm-project/clang-tools-extra/clangd
Hans Wennborg 8ba442bc21 Revert "Following up on PR48517, fix handling of template arguments that refer"
Combined with 'da98651 - Revert "DR2064:
decltype(E) is only a dependent', this change (5a391d3) caused verifier
errors when building Chromium. See https://crbug.com/1168494#c1 for a
reproducer.

Additionally it reverts changes that were dependent on this one, see
below.

> Following up on PR48517, fix handling of template arguments that refer
> to dependent declarations.
>
> Treat an id-expression that names a local variable in a templated
> function as being instantiation-dependent.
>
> This addresses a language defect whereby a reference to a dependent
> declaration can be formed without any construct being value-dependent.
> Fixing that through value-dependence turns out to be problematic, so
> instead this patch takes the approach (proposed on the core reflector)
> of allowing the use of pointers or references to (but not values of)
> dependent declarations inside value-dependent expressions, and instead
> treating template arguments as dependent if they evaluate to a constant
> involving such dependent declarations.
>
> This ends up affecting a bunch of OpenMP tests, due to OpenMP
> imprecisely handling instantiation-dependent constructs, bailing out
> early instead of processing dependent constructs to the extent possible
> when handling the template.
>
> Previously committed as 8c1f2d15b8, and
> reverted because a dependency commit was reverted.

This reverts commit 5a391d38ac.

It also restores clang/test/SemaCXX/coroutines.cpp to its state before
da986511fb.

Revert "[c++20] P1907R1: Support for generalized non-type template arguments of scalar type."

> Previously committed as 9e08e51a20, and
> reverted because a dependency commit was reverted. This incorporates the
> following follow-on commits that were also reverted:
>
> 7e84aa1b81 by Simon Pilgrim
> ed13d8c667 by me
> 95c7b6cadb by Sam McCall
> 430d5d8429 by Dave Zarzycki

This reverts commit 4b574008ae.

Revert "[msabi] Mangle a template argument referring to array-to-pointer decay"

> [msabi] Mangle a template argument referring to array-to-pointer decay
> applied to an array the same as the array itself.
>
> This follows MS ABI, and corrects a regression from the implementation
> of generalized non-type template parameters, where we "forgot" how to
> mangle this case.

This reverts commit 18e093faf7.
2021-01-20 15:55:35 +01:00
..
benchmarks [clangd] Add bencmark for measuring latency of DecisionForest model. 2020-10-02 18:04:31 +02:00
fuzzer [clangd] Fix fuzzer build after 7ba0779fbb 2020-09-30 11:02:05 +02:00
include-mapping [clangd] Add include-mapping for C symbols. 2019-06-21 13:32:18 +00:00
index Revert "Following up on PR48517, fix handling of template arguments that refer" 2021-01-20 15:55:35 +01:00
indexer [clangd] Improve clangd-indexer performance 2020-11-11 14:38:06 +03:00
quality [clangd] Update CC Ranking model with better sampling. 2021-01-15 18:13:24 +01:00
refactor [clangd] Make ExpandAutoType not available on template params. 2021-01-15 14:19:05 +01:00
support [clangd] Use atomics instead of locks to track periodic memory trimming 2020-12-22 22:32:22 +01:00
test [clangd] Index local classes, virtual and overriding methods. 2021-01-19 16:18:48 +01:00
tool [clangd] Retire some flags for uncontroversial, stable features. 2021-01-20 11:47:12 +01:00
unittests [clangd] Extend find-refs to include overrides. 2021-01-20 13:23:20 +01:00
xpc [clangd] makeStringError,make_error<StringError> -> error() 2020-09-14 11:48:31 +02:00
AST.cpp Fix the warnings on unused variables (NFC) 2021-01-13 13:32:40 -08:00
AST.h [clangd] Smarter hover on auto and decltype 2020-12-18 16:27:09 +01:00
ASTSignals.cpp [clangd] Trivial: Documentation fix in ASTSignals. 2021-01-14 18:38:42 +01:00
ASTSignals.h [clangd] Trivial: Documentation fix in ASTSignals. 2021-01-14 18:38:42 +01:00
CMakeLists.txt [clangd] Make AST-based signals available to runWithPreamble. 2021-01-14 18:34:50 +01:00
CSymbolMap.inc [clangd] Add include-mapping for C symbols. 2019-06-21 13:32:18 +00:00
ClangdLSPServer.cpp [clangd] Add server capability advertising hot-reloading of CDBs. 2021-01-07 13:39:21 +01:00
ClangdLSPServer.h [clangd] Use atomics instead of locks to track periodic memory trimming 2020-12-22 22:32:22 +01:00
ClangdServer.cpp [clangd] Retire some flags for uncontroversial, stable features. 2021-01-20 11:47:12 +01:00
ClangdServer.h [clangd] Retire some flags for uncontroversial, stable features. 2021-01-20 11:47:12 +01:00
CodeComplete.cpp [clangd] Fix division by zero when computing scores 2021-01-20 12:50:25 +01:00
CodeComplete.h [clangd] Derive new signals in CC from ASTSignals. 2021-01-18 17:37:27 +01:00
CodeCompletionStrings.cpp [clangd] Fix invalid UTF8 when extracting doc comments. 2020-09-30 16:05:12 +02:00
CodeCompletionStrings.h [clangd] Place cursor better after completing patterns 2019-05-28 15:33:37 +00:00
CollectMacros.cpp [clangd] Add main file macros into the main-file index. 2021-01-14 15:10:17 +03:00
CollectMacros.h [clangd] Add main file macros into the main-file index. 2021-01-14 15:10:17 +03:00
CompileCommands.cpp [clangd] NFC: Use SmallVector<T> where possible 2020-12-10 13:36:49 +01:00
CompileCommands.h [clangd] NFC: Use SmallVector<T> where possible 2020-12-10 13:36:49 +01:00
Compiler.cpp [clangd] Remove the recovery-ast options. 2021-01-20 11:23:57 +01:00
Compiler.h [clangd] Retire some flags for uncontroversial, stable features. 2021-01-20 11:47:12 +01:00
Config.cpp [clangd] config() -> Config::current to avoid confict with NS 2020-06-29 23:05:19 +02:00
Config.h [clangd] Introduce ProjectAwareIndex 2020-11-22 20:59:37 +01:00
ConfigCompile.cpp [clangd] Validate clang-tidy Checks in clangd config. 2020-12-15 21:10:57 +00:00
ConfigFragment.h [clangd] Introduce config parsing for External blocks 2020-11-22 20:59:37 +01:00
ConfigProvider.cpp [clangd][NFC] Small tweak to combined provider 2020-12-08 17:12:56 +00:00
ConfigProvider.h [clangd] Publish config file errors over LSP 2020-12-07 11:07:32 +01:00
ConfigYAML.cpp [clangd] Provide suggestions with invalid config keys 2020-12-15 18:16:17 +00:00
Diagnostics.cpp [clangd] Publish config file errors over LSP 2020-12-07 11:07:32 +01:00
Diagnostics.h [clangd] Publish config file errors over LSP 2020-12-07 11:07:32 +01:00
DraftStore.cpp [clangd] Add error() function for creating formatv-style llvm::Errors. NFC 2020-09-14 10:43:42 +02:00
DraftStore.h [clangd] Move non-clang base pieces into separate support/ lib. NFCI 2020-04-29 15:57:12 +02:00
DumpAST.cpp Revert "Following up on PR48517, fix handling of template arguments that refer" 2021-01-20 15:55:35 +01:00
DumpAST.h [clangd] Add textDocument/ast extension method to dump the AST 2020-11-20 01:13:28 +01:00
ExpectedTypes.cpp Make llvm::StringRef to std::string conversions explicit. 2020-01-28 23:25:25 +01:00
ExpectedTypes.h
FS.cpp Make llvm::StringRef to std::string conversions explicit. 2020-01-28 23:25:25 +01:00
FS.h [clangd] Move non-clang base pieces into separate support/ lib. NFCI 2020-04-29 15:57:12 +02:00
Features.inc.in [clangd] Trim memory periodically when using glibc malloc 2020-12-22 08:54:28 +01:00
FileDistance.cpp [clangd] NFC: Use SmallVector<T> where possible 2020-12-10 13:36:49 +01:00
FileDistance.h Move endian constant from Host.h to SwapByteOrder.h, prune include 2019-10-19 00:48:11 +00:00
FindSymbols.cpp [clangd] Fix division by zero when computing scores 2021-01-20 12:50:25 +01:00
FindSymbols.h [clang-tools-extra] NFC: Fix trivial typo in documents and comments 2020-04-05 15:28:40 +09:00
FindTarget.cpp Revert "Following up on PR48517, fix handling of template arguments that refer" 2021-01-20 15:55:35 +01:00
FindTarget.h [clangd] Avoid recursion in TargetFinder::add() 2021-01-12 13:57:54 -05:00
Format.cpp Lexer: Update the Lexer to use MemoryBufferRef, NFC 2020-10-19 19:10:21 -04:00
Format.h [clangd] Revamp textDocument/onTypeFormatting. 2019-06-10 14:26:21 +00:00
FuzzyMatch.cpp
FuzzyMatch.h
GlobalCompilationDatabase.cpp [clangd] Move DirBasedCDB broadcasting onto its own thread. 2021-01-20 11:22:55 +01:00
GlobalCompilationDatabase.h [clangd] Move DirBasedCDB broadcasting onto its own thread. 2021-01-20 11:22:55 +01:00
HeaderSourceSwitch.cpp [clangd][NFC] Use PathRef for getCorrespondingHeaderOrSource 2021-01-07 02:41:19 +00:00
HeaderSourceSwitch.h [clangd][NFC] Use PathRef for getCorrespondingHeaderOrSource 2021-01-07 02:41:19 +00:00
Headers.cpp [clangd] locateMacroAt handles patched macros 2020-05-29 12:46:54 +02:00
Headers.h [clangd] Add llvm:: qualifier to work around GCC bug. NFC 2020-12-17 12:51:12 +01:00
Hover.cpp [clangd] Make our printing policies for Hover more consistent, especially tags 2020-12-19 00:52:55 +01:00
Hover.h [clangd] Improve hover on arguments to function call 2020-07-03 11:51:15 +02:00
IncludeFixer.cpp [clangd] Value initialize SymbolIDs 2020-11-02 11:37:47 +01:00
IncludeFixer.h [clangd] Compute scopes eagerly in IncludeFixer 2019-08-06 11:37:50 +00:00
JSONTransport.cpp [clangd] Avoid reallocating buffers for each message read: 2021-01-13 17:40:33 +01:00
ParsedAST.cpp [clangd] Retire some flags for uncontroversial, stable features. 2021-01-20 11:47:12 +01:00
ParsedAST.h [clangd] Express dumpAST in tests as a customAction() 2020-08-13 14:27:32 +02:00
PathMapping.cpp [clangd] Add error() function for creating formatv-style llvm::Errors. NFC 2020-09-14 10:43:42 +02:00
PathMapping.h [clangd] Add path mappings functionality 2020-01-07 12:40:51 +01:00
Preamble.cpp Frontend: Change ComputePreambleBounds to take MemoryBufferRef, NFC 2020-11-11 17:19:51 -05:00
Preamble.h [clangd] Make use of preamble bounds from the patch inside ReplayPreamble 2020-06-17 18:32:59 +02:00
Protocol.cpp [clangd] Add textDocument/ast extension method to dump the AST 2020-11-20 01:13:28 +01:00
Protocol.h [clangd] Add textDocument/ast extension method to dump the AST 2020-11-20 01:13:28 +01:00
Quality.cpp [clangd] Use ASTSignals in Heuristics CC Ranking. 2021-01-19 19:48:42 +01:00
Quality.h [clangd] Derive new signals in CC from ASTSignals. 2021-01-18 17:37:27 +01:00
QueryDriverDatabase.cpp [clangd] Split out a base class for delegating GlobalCompilationDatabases. NFC 2021-01-13 16:20:33 +01:00
README.md [clangd] Add README pointing to docs, bugtracker etc. NFC 2020-03-12 14:00:08 +01:00
RIFF.cpp [clangd] Add error() function for creating formatv-style llvm::Errors. NFC 2020-09-14 10:43:42 +02:00
RIFF.h [clangd] Improve serialization error messages. NFC 2020-07-08 17:31:40 +02:00
Selection.cpp Remove references to the ast_type_traits namespace 2020-12-11 00:58:46 +01:00
Selection.h Remove references to the ast_type_traits namespace 2020-12-11 00:58:46 +01:00
SemanticHighlighting.cpp [clangd] Add main file macros into the main-file index. 2021-01-14 15:10:17 +03:00
SemanticHighlighting.h [clangd] Support textDocument/semanticTokens/edits 2020-04-02 17:38:29 +02:00
SemanticSelection.cpp [clang] Simplify buildSyntaxTree API 2020-11-09 22:49:54 +01:00
SemanticSelection.h [clangd] Implement textDocument/foldingRange 2020-07-14 09:28:42 +02:00
SourceCode.cpp [clangd] Fix locateMacroAt() for macro definition outside preamble 2020-12-13 18:33:33 -05:00
SourceCode.h [clangd] Add isKeyword function. 2020-10-05 15:11:24 +02:00
StdSymbolMap.inc [clangd] Add include-mapping for C symbols. 2019-06-21 13:32:18 +00:00
TUScheduler.cpp [clangd] Make AST-based signals available to runWithPreamble. 2021-01-14 18:34:50 +01:00
TUScheduler.h [clangd] Make AST-based signals available to runWithPreamble. 2021-01-14 18:34:50 +01:00
TidyProvider.cpp [clangd] Fix windows path handling in .clang-tidy parsing 2020-12-19 02:24:25 +01:00
TidyProvider.h [clangd] Validate clang-tidy Checks in clangd config. 2020-12-15 21:10:57 +00:00
Transport.h [NFC] Fix typos in Clangd and Clang 2019-12-16 10:54:40 +01:00
URI.cpp [clangd] Remove dead variable. NFC 2020-09-30 23:19:15 +02:00
URI.h [clangd] Simplify the callside of URI::resolve, NFC. 2019-09-23 14:39:37 +00:00
XRefs.cpp [clangd] Extend find-refs to include overrides. 2021-01-20 13:23:20 +01:00
XRefs.h [clangd] go-to-implementation on a base class jumps to all subclasses. 2021-01-08 13:50:57 +01:00

README.md

clangd

clangd is a language server, and provides C++ IDE features to editors. This is not its documentation.

Communication channels

If you have any questions or feedback, you can reach community and developers through one of these channels: