mirror of
https://github.com/RPCSX/llvm.git
synced 2024-12-01 07:30:31 +00:00
NFC: disallow comparison of AtomicOrdering
Follow-up to D18775 and related clang change. AtomicOrdering is a lattice, 'stronger' is the right thing to do, direct comparison is fraught with peril. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@265685 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
d04d5a974e
commit
fb9ead0bd9
@ -53,6 +53,11 @@ enum class AtomicOrdering {
|
||||
SequentiallyConsistent = 7
|
||||
};
|
||||
|
||||
bool operator<(AtomicOrdering, AtomicOrdering) = delete;
|
||||
bool operator>(AtomicOrdering, AtomicOrdering) = delete;
|
||||
bool operator<=(AtomicOrdering, AtomicOrdering) = delete;
|
||||
bool operator>=(AtomicOrdering, AtomicOrdering) = delete;
|
||||
|
||||
/// String used by LLVM IR to represent atomic ordering.
|
||||
static inline const char *toIRString(AtomicOrdering ao) {
|
||||
static const char *names[8] = {"not_atomic", "unordered", "monotonic",
|
||||
|
Loading…
Reference in New Issue
Block a user