Drop unnecessary static_cast.
authorRafael Espindola <rafael.espindola@gmail.com>
Wed, 5 Aug 2015 11:53:59 +0000 (11:53 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Wed, 5 Aug 2015 11:53:59 +0000 (11:53 +0000)
ELFT::TargetEndianness already has the correct type.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@244032 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/Object/ELFObjectFile.h

index 2a870bdbca94522b96412fd9475c8e11a3ed443a..cde5f8dc51ebbc0687cbfb26b87690b3e9e4e93b 100644 (file)
@@ -734,9 +734,7 @@ ELFObjectFile<ELFT>::getRela(DataRefImpl Rela) const {
 template <class ELFT>
 ELFObjectFile<ELFT>::ELFObjectFile(MemoryBufferRef Object, std::error_code &EC)
     : ELFObjectFileBase(
-          getELFType(static_cast<endianness>(ELFT::TargetEndianness) ==
-                         support::little,
-                     ELFT::Is64Bits),
+          getELFType(ELFT::TargetEndianness == support::little, ELFT::Is64Bits),
           Object),
       EF(Data.getBuffer(), EC) {}