Skip to content

Commit ce8bace

Browse files
authored
Merge pull request rust-lang#19067 from cessen/update_tenthash
Update TentHash to version 1.0
2 parents 2386e95 + 22b8339 commit ce8bace

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

src/tools/rust-analyzer/Cargo.lock

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2001,9 +2001,9 @@ dependencies = [
20012001

20022002
[[package]]
20032003
name = "tenthash"
2004-
version = "0.4.0"
2004+
version = "1.0.0"
20052005
source = "registry+https://github.com/rust-lang/crates.io-index"
2006-
checksum = "d67f9f3cf70e0852941d7bc3cb884b49b24b8ee956baf91ad0abae31f5ef11fb"
2006+
checksum = "2d092d622df8bb64e5de8dc86a3667702d5f1e0fe2f0604c6035540703c8cd1e"
20072007

20082008
[[package]]
20092009
name = "test-fixture"

src/tools/rust-analyzer/crates/rust-analyzer/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ rustc-hash.workspace = true
3737
serde_json = { workspace = true, features = ["preserve_order"] }
3838
serde.workspace = true
3939
serde_derive.workspace = true
40-
tenthash = "0.4.0"
40+
tenthash = "1.0.0"
4141
num_cpus = "1.15.0"
4242
mimalloc = { version = "0.1.30", default-features = false, optional = true }
4343
lsp-server.workspace = true

src/tools/rust-analyzer/crates/rust-analyzer/src/lib.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ mod integrated_benchmarks;
5050
use hir::Mutability;
5151
use ide::{CompletionItem, CompletionItemRefMode, CompletionRelevance};
5252
use serde::de::DeserializeOwned;
53-
use tenthash::TentHasher;
53+
use tenthash::TentHash;
5454

5555
pub use crate::{
5656
lsp::capabilities::server_capabilities, main_loop::main_loop, reload::ws_to_crate_graph,
@@ -66,7 +66,7 @@ pub fn from_json<T: DeserializeOwned>(
6666
}
6767

6868
fn completion_item_hash(item: &CompletionItem, is_ref_completion: bool) -> [u8; 20] {
69-
fn hash_completion_relevance(hasher: &mut TentHasher, relevance: &CompletionRelevance) {
69+
fn hash_completion_relevance(hasher: &mut TentHash, relevance: &CompletionRelevance) {
7070
use ide_completion::{
7171
CompletionRelevancePostfixMatch, CompletionRelevanceReturnType,
7272
CompletionRelevanceTypeMatch,
@@ -108,7 +108,7 @@ fn completion_item_hash(item: &CompletionItem, is_ref_completion: bool) -> [u8;
108108
}
109109
}
110110

111-
let mut hasher = TentHasher::new();
111+
let mut hasher = TentHash::new();
112112
hasher.update([
113113
u8::from(is_ref_completion),
114114
u8::from(item.is_snippet),

0 commit comments

Comments
 (0)