[PATCH] D54662: [WebAssembly] Add equality comparison operators for WasmEventType
Heejin Ahn via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 16 18:16:15 PST 2018
aheejin created this revision.
aheejin added a reviewer: sbc100.
Herald added subscribers: llvm-commits, sunfish, jgravelle-google, dschuff.
This was missing in https://reviews.llvm.org/D54096. Independent tests for this is not available
here, because these are used in lld.
Repository:
rL LLVM
https://reviews.llvm.org/D54662
Files:
include/llvm/BinaryFormat/Wasm.h
Index: include/llvm/BinaryFormat/Wasm.h
===================================================================
--- include/llvm/BinaryFormat/Wasm.h
+++ include/llvm/BinaryFormat/Wasm.h
@@ -331,6 +331,14 @@
return !(LHS == RHS);
}
+inline bool operator==(const WasmEventType &LHS, const WasmEventType &RHS) {
+ return LHS.Attribute == RHS.Attribute && LHS.SigIndex == RHS.SigIndex;
+}
+
+inline bool operator!=(const WasmEventType &LHS, const WasmEventType &RHS) {
+ return !(LHS == RHS);
+}
+
std::string toString(wasm::WasmSymbolType type);
std::string relocTypetoString(uint32_t type);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D54662.174491.patch
Type: text/x-patch
Size: 597 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20181117/5839bcc5/attachment.bin>
More information about the llvm-commits
mailing list