Fix another compilation error from r266919 for clang-atom-d525-fedora-rel which

is another place that libObject’s getName() for symbols returns Expected<...>
that needed to be updated.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@266933 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Kevin Enderby 2016-04-20 23:10:14 +00:00
parent 9de39018da
commit 288715baa4

View File

@ -120,9 +120,12 @@ void IntelJITEventListener::NotifyObjectEmitted(
if (SymType != SymbolRef::ST_Function)
continue;
ErrorOr<StringRef> Name = Sym.getName();
if (!Name)
Expected<StringRef> Name = Sym.getName();
if (!Name) {
// TODO: Actually report errors helpfully.
consumeError(Name.takeError());
continue;
}
ErrorOr<uint64_t> AddrOrErr = Sym.getAddress();
if (AddrOrErr.getError())