OSDN Git Service

Fix BB after r354328.
authorGeorge Rimar <grimar@accesssoftek.com>
Tue, 19 Feb 2019 14:22:10 +0000 (14:22 +0000)
committerGeorge Rimar <grimar@accesssoftek.com>
Tue, 19 Feb 2019 14:22:10 +0000 (14:22 +0000)
commit6e4454157849d1d94ad5c2a863201f4ecc9d5b37
tree03c70d0e906cf8dd6176526e4b8f7c1c3f26154c
parentca483bfba2aba968dfb1caa0a397adee4093d51d
Fix BB after r354328.

Bot:
http://lab.llvm.org:8011/builders/lld-x86_64-darwin13/builds/30188/steps/build_Lld/logs/stdio

Error:
/Users/buildslave/as-bldslv9_new/lld-x86_64-darwin13/llvm.src/lib/ObjectYAML/ELFYAML.cpp:1013:15: error: unused variable 'Object' [-Werror,-Wunused-variable]
  const auto *Object = static_cast<ELFYAML::Object *>(IO.getContext());
              ^
/Users/buildslave/as-bldslv9_new/lld-x86_64-darwin13/llvm.src/lib/ObjectYAML/ELFYAML.cpp:1023:15: error: unused variable 'Object' [-Werror,-Wunused-variable]
  const auto *Object = static_cast<ELFYAML::Object *>(IO.getContext());

Fix:
change
  const auto *Object = static_cast<ELFYAML::Object *>(IO.getContext());
  assert(Object && "The IO context is not initialized");
to
  assert(!IO.getContext() && "The IO context is initialized already");

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@354329 91177308-0d34-0410-b5e6-96231b3b80d8
lib/ObjectYAML/ELFYAML.cpp