llvm-project/clang/unittests
Sam McCall 32ef52063c [AST] Fix double-traversal of code in top-level lambdas in RAV(implicit = yes).
Summary:
Prior to r351069, lambda classes were traversed or not depending on the
{Function, Class, Namespace, TU} DeclContext containing them.
If it was a function (common case) they were not traversed.
If it was a namespace or TU (top-level lambda) they were traversed as part of
that DeclContext traversal.

r351069 "fixed" RAV to traverse these as part of the LambdaExpr, which is the
right place. But top-level lambdas are now traversed twice.
We fix that as blocks and block captures were apparently fixed in the past.

Maybe it would be nicer to avoid adding the lambda classes to the DeclContext
in the first place, but I can't work out the implications of that.

Reviewers: bkramer, klimek

Subscribers: cfe-commits

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

llvm-svn: 351075
2019-01-14 17:16:00 +00:00
..
AST [AST] RecursiveASTVisitor visits lambda classes when implicit visitation is on. 2019-01-14 10:31:42 +00:00
ASTMatchers [clang] Add AST matcher for initializer list members 2019-01-07 14:14:36 +00:00
Analysis Fix use-after-free bug in Tooling. 2019-01-08 16:55:13 +00:00
Basic Remove stat cache chaining as it's no longer needed after PTH support has been 2018-12-21 19:33:09 +00:00
CodeGen Add explicit dependency on clangSerialization for a bunch of components to fix -DBUILD_SHARED_LIBS=on build 2018-12-12 08:02:18 +00:00
CrossTU Add explicit dependency on clangSerialization for a bunch of components to fix -DBUILD_SHARED_LIBS=on build 2018-12-12 08:02:18 +00:00
Driver [Distro] Support detecting Gentoo 2018-12-23 15:07:19 +00:00
Format clang-format: [JS] support goog.requireType. 2019-01-07 13:12:50 +00:00
Frontend Add explicit dependency on clangSerialization for a bunch of components to fix -DBUILD_SHARED_LIBS=on build 2018-12-12 08:02:18 +00:00
Index Add explicit dependency on clangSerialization for a bunch of components to fix -DBUILD_SHARED_LIBS=on build 2018-12-12 08:02:18 +00:00
Lex Silence -Wsign-compare in unittests 2019-01-11 16:53:45 +00:00
Rename Add explicit dependency on clangSerialization for a bunch of components to fix -DBUILD_SHARED_LIBS=on build 2018-12-12 08:02:18 +00:00
Rewrite [CMake] Use PRIVATE in target_link_libraries for executables 2017-12-05 21:49:56 +00:00
Sema [CodeComplete] Fix test failure on different host and target configs 2018-12-17 16:37:52 +00:00
StaticAnalyzer [analyzer] Pass the correct loc Expr from VisitIncDecOp to evalStore 2019-01-07 15:07:01 +00:00
Tooling [AST] Fix double-traversal of code in top-level lambdas in RAV(implicit = yes). 2019-01-14 17:16:00 +00:00
libclang [libclang] Recommit r336590 with a fix for the memory leak in the test 2019-01-08 22:32:51 +00:00
CMakeLists.txt [Index] Add an option to collect macros from preprocesor. 2018-09-18 08:51:08 +00:00