Switch InitializedEntity from TypeLoc down to just QualTypes, since we don't use the location information but we did spend a bunch of time building faked-up TypeLocs
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91905 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/SemaExprCXX.cpp b/lib/Sema/SemaExprCXX.cpp
index 7c4ab89..92a94da 100644
--- a/lib/Sema/SemaExprCXX.cpp
+++ b/lib/Sema/SemaExprCXX.cpp
@@ -446,18 +446,9 @@
ConstructorLParen,
ConstructorRParen);
- // FIXME: We shouldn't have to fake this.
- TypeSourceInfo *TInfo
- = Context.getTrivialTypeSourceInfo(AllocType, TypeLoc);
InitializedEntity Entity
- = InitializedEntity::InitializeNew(StartLoc, TInfo->getTypeLoc());
+ = InitializedEntity::InitializeNew(StartLoc, AllocType);
InitializationSequence InitSeq(*this, Entity, Kind, ConsArgs, NumConsArgs);
-
- if (!InitSeq) {
- InitSeq.Diagnose(*this, Entity, Kind, ConsArgs, NumConsArgs);
- return ExprError();
- }
-
OwningExprResult FullInit = InitSeq.Perform(*this, Entity, Kind,
move(ConstructorArgs));
if (FullInit.isInvalid())