Skip to content
This repository was archived by the owner on Jun 26, 2020. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion cranelift-entity/src/primary.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ use std::vec::Vec;
/// that it only allows indexing with the distinct `EntityRef` key type, so converting to a
/// plain slice would make it easier to use incorrectly. To make a slice of a `PrimaryMap`, use
/// `into_boxed_slice`.
#[derive(Debug, Clone)]
#[derive(Debug, Clone, Hash)]
#[cfg_attr(feature = "enable-serde", derive(Serialize, Deserialize))]
pub struct PrimaryMap<K, V>
where
Expand Down
10 changes: 5 additions & 5 deletions cranelift-wasm/src/translation_utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ pub struct SignatureIndex(u32);
entity_impl!(SignatureIndex);

/// WebAssembly global.
#[derive(Debug, Clone, Copy)]
#[derive(Debug, Clone, Copy, Hash)]
pub struct Global {
/// The type of the value stored in the global.
pub ty: ir::Type,
Expand All @@ -65,7 +65,7 @@ pub struct Global {
}

/// Globals are initialized via the four `const` operators or by referring to another import.
#[derive(Debug, Clone, Copy)]
#[derive(Debug, Clone, Copy, Hash)]
pub enum GlobalInit {
/// An `i32.const`.
I32Const(i32),
Expand All @@ -82,7 +82,7 @@ pub enum GlobalInit {
}

/// WebAssembly table.
#[derive(Debug, Clone, Copy)]
#[derive(Debug, Clone, Copy, Hash)]
pub struct Table {
/// The type of data stored in elements of the table.
pub ty: TableElementType,
Expand All @@ -93,7 +93,7 @@ pub struct Table {
}

/// WebAssembly table element. Can be a function or a scalar type.
#[derive(Debug, Clone, Copy)]
#[derive(Debug, Clone, Copy, Hash)]
pub enum TableElementType {
/// A scalar type.
Val(ir::Type),
Expand All @@ -102,7 +102,7 @@ pub enum TableElementType {
}

/// WebAssembly linear memory.
#[derive(Debug, Clone, Copy)]
#[derive(Debug, Clone, Copy, Hash)]
pub struct Memory {
/// The minimum number of pages in the memory.
pub minimum: u32,
Expand Down