wasm-tools icon indicating copy to clipboard operation
wasm-tools copied to clipboard

Implement `Hash` on types

Open RReverser opened this issue 6 years ago • 2 comments

Currently even data enums and structs (e.g. Type, FuncType, NameEntry, etc.), are missing Hash implementation, which makes it hard to use them in a HashMap for caching.

Would it be possible to add simple #[derive(Hash)] to all non-builder structs?

RReverser avatar Nov 25 '19 20:11 RReverser

@fitzgen I suspect you tagged / closed the wrong issue with that commit.

RReverser avatar Oct 21 '20 18:10 RReverser

ah this was accidental, as part of merging wasm-smith into this repo. woops!

fitzgen avatar Oct 21 '20 18:10 fitzgen