diff options
| author | Rafael Espindola <rafael.espindola@gmail.com> | 2014-01-08 22:00:09 +0000 |
|---|---|---|
| committer | Rafael Espindola <rafael.espindola@gmail.com> | 2014-01-08 22:00:09 +0000 |
| commit | d28918b28996051a156f4ee0c11c884ea3cbcdc9 (patch) | |
| tree | 578350222de8187727fd44d68fa3de7f0f5dcea1 /lld/lib/Driver/WinLinkInputGraph.cpp | |
| parent | 98f3de8880d4d387135b1a8407ba82d212b00862 (diff) | |
| download | bcm5719-llvm-d28918b28996051a156f4ee0c11c884ea3cbcdc9.tar.gz bcm5719-llvm-d28918b28996051a156f4ee0c11c884ea3cbcdc9.zip | |
Use getError instead of the error_code operator.
llvm-svn: 198797
Diffstat (limited to 'lld/lib/Driver/WinLinkInputGraph.cpp')
| -rw-r--r-- | lld/lib/Driver/WinLinkInputGraph.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lld/lib/Driver/WinLinkInputGraph.cpp b/lld/lib/Driver/WinLinkInputGraph.cpp index 7db58628d05..60bfa47c1e6 100644 --- a/lld/lib/Driver/WinLinkInputGraph.cpp +++ b/lld/lib/Driver/WinLinkInputGraph.cpp @@ -15,9 +15,9 @@ namespace lld { error_code PECOFFFileNode::parse(const LinkingContext &ctx, raw_ostream &diagnostics) { ErrorOr<StringRef> filePath = getPath(ctx); - if (!filePath) { + if (error_code ec = filePath.getError()) { diagnostics << "File not found: " << _path << "\n"; - return error_code(filePath); + return ec; } if (error_code ec = getBuffer(*filePath)) { |

