Skip to content

Commit

Permalink
compat/bswap.h: simplify MSVC endianness detection
Browse files Browse the repository at this point in the history
Modern MSVC or Windows versions don't support big-endian, so it's
unnecessary to consider architectures when using it.

This also makes ARM64 MSVC builds succeed.

Helped-by: brian m. carlson <[email protected]>
Signed-off-by: Daniel Gurney <[email protected]>
Signed-off-by: Junio C Hamano <[email protected]>
  • Loading branch information
dgurney authored and gitster committed Nov 9, 2020
1 parent 898f807 commit 1af265f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion compat/bswap.h
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ static inline uint64_t git_bswap64(uint64_t x)
}
#endif

#elif defined(_MSC_VER) && (defined(_M_IX86) || defined(_M_X64))
#elif defined(_MSC_VER)

#include <stdlib.h>

Expand Down

0 comments on commit 1af265f

Please sign in to comment.