зеркало из https://github.com/microsoft/clang-1.git
The allocated exception slot does not alias anything; should fix self-host.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138615 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Родитель
669cffa41a
Коммит
1366862c3f
|
@ -1034,7 +1034,8 @@ static void InitCatchParam(CodeGenFunction &CGF,
|
|||
// Perform the copy construction.
|
||||
CGF.EmitAggExpr(copyExpr, AggValueSlot::forAddr(ParamAddr, Qualifiers(),
|
||||
AggValueSlot::IsNotDestructed,
|
||||
AggValueSlot::DoesNotNeedGCBarriers));
|
||||
AggValueSlot::DoesNotNeedGCBarriers,
|
||||
AggValueSlot::IsNotAliased));
|
||||
|
||||
// Leave the terminate scope.
|
||||
CGF.EHStack.popTerminate();
|
||||
|
|
|
@ -390,3 +390,16 @@ namespace test7 {
|
|||
return new B(A(), new B(A(), 0));
|
||||
}
|
||||
}
|
||||
|
||||
// Just don't crash.
|
||||
namespace test8 {
|
||||
struct A {
|
||||
A(const A&);
|
||||
~A();
|
||||
};
|
||||
|
||||
A makeA();
|
||||
void test() {
|
||||
throw makeA();
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче