mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-12-28 18:54:55 +00:00
Update for LLVM api change
llvm-svn: 216394
This commit is contained in:
parent
3fd1e9933f
commit
ac27f730d7
@ -130,14 +130,14 @@ bool JSONExporter::runOnScop(Scop &scop) {
|
||||
std::string fileContent = writer.write(jscop);
|
||||
|
||||
// Write to file.
|
||||
std::string ErrInfo;
|
||||
tool_output_file F(FileName.c_str(), ErrInfo, llvm::sys::fs::F_Text);
|
||||
std::error_code EC;
|
||||
tool_output_file F(FileName, EC, llvm::sys::fs::F_Text);
|
||||
|
||||
std::string FunctionName = R.getEntry()->getParent()->getName();
|
||||
errs() << "Writing JScop '" << R.getNameStr() << "' in function '"
|
||||
<< FunctionName << "' to '" << FileName << "'.\n";
|
||||
|
||||
if (ErrInfo.empty()) {
|
||||
if (!EC) {
|
||||
F.os() << fileContent;
|
||||
F.os().close();
|
||||
if (!F.os().has_error()) {
|
||||
|
Loading…
Reference in New Issue
Block a user