diff --git a/Cargo.lock b/Cargo.lock index aaa86c36..b724d8dc 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -257,7 +257,7 @@ checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" [[package]] name = "candid" -version = "0.9.5" +version = "0.9.6" dependencies = [ "anyhow", "arbitrary", diff --git a/rust/candid/Cargo.toml b/rust/candid/Cargo.toml index 170a253b..42150428 100644 --- a/rust/candid/Cargo.toml +++ b/rust/candid/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "candid" -version = "0.9.5" +version = "0.9.6" edition = "2021" authors = ["DFINITY Team"] description = "Candid is an interface description language (IDL) for interacting with canisters running on the Internet Computer." diff --git a/rust/candid/src/bindings/rust.rs b/rust/candid/src/bindings/rust.rs index 4069ec12..2e347bc4 100644 --- a/rust/candid/src/bindings/rust.rs +++ b/rust/candid/src/bindings/rust.rs @@ -62,7 +62,7 @@ fn ident_(id: &str, case: Option) -> (RcDoc, bool) { || id.starts_with(|c: char| !c.is_ascii_alphabetic() && c != '_') || id.chars().any(|c| !c.is_ascii_alphanumeric() && c != '_') { - return (RcDoc::text(format!("_{}_", crate::idl_hash(&id))), true); + return (RcDoc::text(format!("_{}_", crate::idl_hash(id))), true); } let (is_rename, id) = if let Some(case) = case { let new_id = id.to_case(case);