Skip to content

Commit 47ca67d

Browse files
committed
[llvm-project] Replace submitted changes with proper backports
1 parent a065cdb commit 47ca67d

File tree

3 files changed

+13
-1
lines changed

3 files changed

+13
-1
lines changed

interpreter/llvm-project/clang/docs/Modules.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -573,6 +573,9 @@ cplusplus14
573573
cplusplus17
574574
C++17 support is available.
575575

576+
cplusplus20
577+
C++20 support is available.
578+
576579
c99
577580
C99 support is available.
578581

interpreter/llvm-project/clang/lib/AST/ExprConstant.cpp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15404,6 +15404,15 @@ bool Expr::EvaluateAsInitializer(APValue &Value, const ASTContext &Ctx,
1540415404
LVal.set(VD);
1540515405

1540615406
{
15407+
// C++23 [intro.execution]/p5
15408+
// A full-expression is ... an init-declarator ([dcl.decl]) or a
15409+
// mem-initializer.
15410+
// So we need to make sure temporary objects are destroyed after having
15411+
// evaluated the expression (per C++23 [class.temporary]/p4).
15412+
//
15413+
// FIXME: Otherwise this may break test/Modules/pr68702.cpp because the
15414+
// serialization code calls ParmVarDecl::getDefaultArg() which strips the
15415+
// outermost FullExpr, such as ExprWithCleanups.
1540715416
FullExpressionRAII Scope(Info);
1540815417
if (!EvaluateInPlace(Value, Info, LVal, this,
1540915418
/*AllowNonLiteralTypes=*/true) ||
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
ROOT-llvm16-20231130-01
1+
ROOT-llvm16-20240115-01

0 commit comments

Comments
 (0)