[all-commits] [llvm/llvm-project] a85b2d: [Clang] only inherit the parent eval context insid...

cor3ntin via All-commits all-commits at lists.llvm.org
Mon Jan 27 12:30:50 PST 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: a85b2dc45a5f1312d6ee5e2522c24e81a086bf60
      https://github.com/llvm/llvm-project/commit/a85b2dc45a5f1312d6ee5e2522c24e81a086bf60
  Author: cor3ntin <corentinjabot at gmail.com>
  Date:   2025-01-27 (Mon, 27 Jan 2025)

  Changed paths:
    M clang/include/clang/AST/ASTLambda.h
    M clang/include/clang/Sema/Sema.h
    M clang/lib/AST/ASTImporter.cpp
    M clang/lib/AST/Expr.cpp
    M clang/lib/CodeGen/CGExpr.cpp
    M clang/lib/Sema/SemaDeclCXX.cpp
    M clang/lib/Sema/SemaTemplateInstantiateDecl.cpp
    M clang/test/SemaCXX/cxx2b-consteval-propagate.cpp

  Log Message:
  -----------
  [Clang] only inherit the parent eval context inside of lambdas (#124426)

As we create defaul constructors lazily, we should not inherit from the
parent evaluation context.
However, we need to make an exception for lambdas (in particular their
conversion operators, which are also implicitly defined).

As a drive-by, we introduce a generic way to query whether a function is
a member of a lambda.

This fixes a regression introduced by baf6bd3.

Fixes #118000



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list