Update for llvm api change.

llvm-svn: 202045
This commit is contained in:
Rafael Espindola 2014-02-24 15:41:44 +00:00
parent c00c6e661f
commit dc59a36caa
5 changed files with 8 additions and 5 deletions

View File

@ -247,7 +247,7 @@ bool writeFiles(const clang::Rewriter &Rewrites) {
std::string ErrorInfo;
llvm::raw_fd_ostream FileStream(FileName, ErrorInfo);
llvm::raw_fd_ostream FileStream(FileName, ErrorInfo, llvm::sys::fs::F_None);
if (!ErrorInfo.empty()) {
errs() << "Warning: Could not write to " << FileName << "\n";
continue;

View File

@ -272,7 +272,8 @@ int main(int argc, char **argv) {
// Write new file to disk
std::string ErrorInfo;
llvm::raw_fd_ostream FileStream(I->getKey().str().c_str(), ErrorInfo);
llvm::raw_fd_ostream FileStream(I->getKey().str().c_str(), ErrorInfo,
llvm::sys::fs::F_None);
if (!ErrorInfo.empty()) {
llvm::errs() << "Could not open " << I->getKey() << " for writing\n";
continue;

View File

@ -51,7 +51,8 @@ void writePerfDataJSON(
<< ".json";
std::string ErrorInfo;
llvm::raw_fd_ostream FileStream(SS.str().c_str(), ErrorInfo);
llvm::raw_fd_ostream FileStream(SS.str().c_str(), ErrorInfo,
llvm::sys::fs::F_None);
FileStream << "{\n";
FileStream << " \"Sources\" : [\n";
for (SourcePerfData::const_iterator I = TimingResults.begin(),

View File

@ -249,7 +249,7 @@ static bool writeModuleMap(llvm::StringRef ModuleMapPath,
// Set up module map output file.
std::string Error;
llvm::tool_output_file Out(FilePath.c_str(), Error);
llvm::tool_output_file Out(FilePath.c_str(), Error, llvm::sys::fs::F_None);
if (!Error.empty()) {
llvm::errs() << Argv0 << ": error opening " << FilePath << ":" << Error
<< "\n";

View File

@ -214,7 +214,8 @@ int main(int Argc, const char **Argv) {
} else {
// Set up output file.
std::string Error;
llvm::tool_output_file Out(OutputFileName.c_str(), Error);
llvm::tool_output_file Out(OutputFileName.c_str(), Error,
llvm::sys::fs::F_None);
if (!Error.empty()) {
llvm::errs() << "pp-trace: error creating " << OutputFileName << ":"
<< Error << "\n";