summaryrefslogtreecommitdiffstats
path: root/llvm/tools/yaml2obj/yaml2elf.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/tools/yaml2obj/yaml2elf.cpp')
-rw-r--r--llvm/tools/yaml2obj/yaml2elf.cpp8
1 files changed, 1 insertions, 7 deletions
diff --git a/llvm/tools/yaml2obj/yaml2elf.cpp b/llvm/tools/yaml2obj/yaml2elf.cpp
index a2ae5e2e756..c98093431a7 100644
--- a/llvm/tools/yaml2obj/yaml2elf.cpp
+++ b/llvm/tools/yaml2obj/yaml2elf.cpp
@@ -558,13 +558,7 @@ static bool isLittleEndian(const ELFYAML::Object &Doc) {
return Doc.Header.Data == ELFYAML::ELF_ELFDATA(ELF::ELFDATA2LSB);
}
-int yaml2elf(yaml::Input &YIn, raw_ostream &Out) {
- ELFYAML::Object Doc;
- YIn >> Doc;
- if (YIn.error()) {
- errs() << "yaml2obj: Failed to parse YAML file!\n";
- return 1;
- }
+int yaml2elf(llvm::ELFYAML::Object &Doc, raw_ostream &Out) {
using object::ELFType;
typedef ELFType<support::little, true> LE64;
typedef ELFType<support::big, true> BE64;
OpenPOWER on IntegriCloud