diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2025-12-27 23:23:22 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2026-04-25 14:14:02 +0000 |
| commit | e64bea71c21eb42e97aa615188ba91f6cce0d36d (patch) | |
| tree | 62aa9d1dc27620bdcc0128f6f1ed30a5eac88b54 /contrib/llvm-project/clang/lib/CodeGen/CGExprConstant.cpp | |
| parent | 770cf0a5f02dc8983a89c6568d741fbc25baa999 (diff) | |
| parent | 294ba569803972323a64670451a82af53c660541 (diff) | |
Diffstat (limited to 'contrib/llvm-project/clang/lib/CodeGen/CGExprConstant.cpp')
| -rw-r--r-- | contrib/llvm-project/clang/lib/CodeGen/CGExprConstant.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/contrib/llvm-project/clang/lib/CodeGen/CGExprConstant.cpp b/contrib/llvm-project/clang/lib/CodeGen/CGExprConstant.cpp index 715bd392f59f..0cc468ca3ab7 100644 --- a/contrib/llvm-project/clang/lib/CodeGen/CGExprConstant.cpp +++ b/contrib/llvm-project/clang/lib/CodeGen/CGExprConstant.cpp @@ -873,8 +873,9 @@ bool ConstStructBuilder::Build(const APValue &Val, const RecordDecl *RD, for (const BaseInfo &Base : Bases) { bool IsPrimaryBase = Layout.getPrimaryBase() == Base.Decl; - Build(Val.getStructBase(Base.Index), Base.Decl, IsPrimaryBase, - VTableClass, Offset + Base.Offset); + if (!Build(Val.getStructBase(Base.Index), Base.Decl, IsPrimaryBase, + VTableClass, Offset + Base.Offset)) + return false; } } @@ -1620,7 +1621,7 @@ llvm::Constant *ConstantEmitter::tryEmitConstantExpr(const ConstantExpr *CE) { if (CE->isGLValue()) RetType = CGM.getContext().getLValueReferenceType(RetType); - return emitAbstract(CE->getBeginLoc(), CE->getAPValueResult(), RetType); + return tryEmitAbstract(CE->getAPValueResult(), RetType); } llvm::Constant * |
