[all-commits] [llvm/llvm-project] 86d1f4: [Support, ADT] Move llvm::endianness to bit.h (#68...
Kazu Hirata via All-commits
all-commits at lists.llvm.org
Thu Oct 5 18:04:00 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 86d1f4c538e50e8f764e7700d167ffd1d8f70102
https://github.com/llvm/llvm-project/commit/86d1f4c538e50e8f764e7700d167ffd1d8f70102
Author: Kazu Hirata <kazu at google.com>
Date: 2023-10-05 (Thu, 05 Oct 2023)
Changed paths:
M llvm/include/llvm/ADT/bit.h
M llvm/include/llvm/Support/Endian.h
M llvm/include/llvm/Support/SwapByteOrder.h
Log Message:
-----------
[Support, ADT] Move llvm::endianness to bit.h (#68280)
In C++20, std::endian comes from `<bit>`. Following the same spirit,
this patch moves llvm::endianness and the endian detection logic to
bit.h.
Without this patch, llvm::endianness::native is defined in terms of
llvm::sys::IsBigEndianHost. This patch reverses the dependency.
llvm::sys::IsBigEndianHost is now defined in terms of
llvm::endianness::native.
More information about the All-commits
mailing list