diff options
Diffstat (limited to 'crates/ra_analysis/src/symbol_index.rs')
-rw-r--r-- | crates/ra_analysis/src/symbol_index.rs | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/crates/ra_analysis/src/symbol_index.rs b/crates/ra_analysis/src/symbol_index.rs index ffbb6a29f..54672fde4 100644 --- a/crates/ra_analysis/src/symbol_index.rs +++ b/crates/ra_analysis/src/symbol_index.rs | |||
@@ -9,7 +9,7 @@ use ra_syntax::{ | |||
9 | }; | 9 | }; |
10 | use fst::{self, Streamer}; | 10 | use fst::{self, Streamer}; |
11 | use rayon::prelude::*; | 11 | use rayon::prelude::*; |
12 | use {Query, FileId, JobToken}; | 12 | use crate::{Query, FileId, JobToken}; |
13 | 13 | ||
14 | #[derive(Debug)] | 14 | #[derive(Debug)] |
15 | pub(crate) struct SymbolIndex { | 15 | pub(crate) struct SymbolIndex { |
@@ -17,6 +17,15 @@ pub(crate) struct SymbolIndex { | |||
17 | map: fst::Map, | 17 | map: fst::Map, |
18 | } | 18 | } |
19 | 19 | ||
20 | impl PartialEq for SymbolIndex { | ||
21 | fn eq(&self, other: &SymbolIndex) -> bool { | ||
22 | self.symbols == other.symbols | ||
23 | } | ||
24 | } | ||
25 | |||
26 | impl Eq for SymbolIndex { | ||
27 | } | ||
28 | |||
20 | impl Hash for SymbolIndex { | 29 | impl Hash for SymbolIndex { |
21 | fn hash<H: Hasher>(&self, hasher: &mut H) { | 30 | fn hash<H: Hasher>(&self, hasher: &mut H) { |
22 | self.symbols.hash(hasher) | 31 | self.symbols.hash(hasher) |