forked from OSchip/llvm-project
[llvm-readobj] Remove dead code. Add an assertion instead.
When we arrive at the end of the function, the validation of the object has been done already. In theory, so, we should never arrive here with something broken as the object isn't mutated. Practice sometimes proves theory to be wrong, so leave an assertion instead, as suggested by David Blaikie, to catch bugs. llvm-svn: 257570
This commit is contained in:
parent
50018d3cf5
commit
25d84580f4
|
@ -1651,8 +1651,9 @@ void llvm::ParseInputMachO(StringRef Filename) {
|
|||
} else
|
||||
errs() << "llvm-objdump: '" << Filename << "': "
|
||||
<< "Object is not a Mach-O file type.\n";
|
||||
} else
|
||||
report_error(Filename, object_error::invalid_file_type);
|
||||
return;
|
||||
}
|
||||
llvm_unreachable("Input object can't be invalid at this point");
|
||||
}
|
||||
|
||||
typedef std::pair<uint64_t, const char *> BindInfoEntry;
|
||||
|
|
Loading…
Reference in New Issue