Skip to content

Commit d496cca

Browse files
committed
Derive hash for BitSet and BitMatrix
1 parent dde825d commit d496cca

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

compiler/rustc_index/src/bit_set.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ macro_rules! bit_relations_inherent_impls {
8787
/// to or greater than the domain size. All operations that involve two bitsets
8888
/// will panic if the bitsets have differing domain sizes.
8989
///
90-
#[derive(Eq, PartialEq, Decodable, Encodable)]
90+
#[derive(Eq, PartialEq, Hash, Decodable, Encodable)]
9191
pub struct BitSet<T> {
9292
domain_size: usize,
9393
words: Vec<Word>,
@@ -987,7 +987,7 @@ impl<T: Idx> GrowableBitSet<T> {
987987
///
988988
/// All operations that involve a row and/or column index will panic if the
989989
/// index exceeds the relevant bound.
990-
#[derive(Clone, Eq, PartialEq, Decodable, Encodable)]
990+
#[derive(Clone, Eq, PartialEq, Hash, Decodable, Encodable)]
991991
pub struct BitMatrix<R: Idx, C: Idx> {
992992
num_rows: usize,
993993
num_columns: usize,

0 commit comments

Comments
 (0)