From: Nicolas Geoffray Date: Sat, 15 Aug 2009 15:41:32 +0000 (+0000) Subject: Use the new API for creating an OpaqueType. X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=bad9defac851d5cf04def7906345812ec270a63a;p=oota-llvm.git Use the new API for creating an OpaqueType. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79107 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/CppBackend/CPPBackend.cpp b/lib/Target/CppBackend/CPPBackend.cpp index 79f1366d7ab..2f5733dae3b 100644 --- a/lib/Target/CppBackend/CPPBackend.cpp +++ b/lib/Target/CppBackend/CPPBackend.cpp @@ -516,7 +516,8 @@ namespace { if (TI != TypeStack.end()) { TypeMap::const_iterator I = UnresolvedTypes.find(Ty); if (I == UnresolvedTypes.end()) { - Out << "PATypeHolder " << typeName << "_fwd = OpaqueType::get();"; + Out << "PATypeHolder " << typeName; + Out << "_fwd = OpaqueType::get(getGlobalContext());"; nl(Out); UnresolvedTypes[Ty] = typeName; } @@ -616,7 +617,8 @@ namespace { break; } case Type::OpaqueTyID: { - Out << "OpaqueType* " << typeName << " = OpaqueType::get();"; + Out << "OpaqueType* " << typeName; + Out << " = OpaqueType::get(getGlobalContext());"; nl(Out); break; }