Shield clang from LLVM API changes, until the dust settles.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@76862 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/CodeGen/CodeGenFunction.cpp b/lib/CodeGen/CodeGenFunction.cpp
index 962f8a0..80cfeff 100644
--- a/lib/CodeGen/CodeGenFunction.cpp
+++ b/lib/CodeGen/CodeGenFunction.cpp
@@ -177,7 +177,9 @@
DI->EmitFunctionStart(CGM.getMangledName(FD), RetTy, CurFn, Builder);
} else {
// Just use LLVM function name.
- DI->EmitFunctionStart(Fn->getName().c_str(),
+
+ // FIXME: Remove unnecessary conversion to std::string when API settles.
+ DI->EmitFunctionStart(std::string(Fn->getName()).c_str(),
RetTy, CurFn, Builder);
}
}