From 6b6a36e47d7986211806e22b4a3bddbb5eda47fd Mon Sep 17 00:00:00 2001 From: Shingo Kato Date: Sun, 20 Sep 2020 11:32:08 +0000 Subject: [PATCH] improvement: bump smol_str dependency to 0.1.17 --- crates/mun_hir/src/name.rs | 6 +++--- crates/mun_syntax/Cargo.toml | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/crates/mun_hir/src/name.rs b/crates/mun_hir/src/name.rs index 4f41f78c1..92691867b 100644 --- a/crates/mun_hir/src/name.rs +++ b/crates/mun_hir/src/name.rs @@ -34,8 +34,8 @@ impl Name { } /// Shortcut to create inline plain text name - const fn new_inline_ascii(text: &[u8]) -> Name { - Name::new_text(SmolStr::new_inline_from_ascii(text.len(), text)) + const fn new_inline(text: &str) -> Name { + Name::new_text(SmolStr::new_inline(text)) } /// Resolve a name from the text of token. @@ -94,7 +94,7 @@ pub mod known { $( #[allow(bad_style)] pub const $ident: super::Name = - super::Name::new_inline_ascii(stringify!($ident).as_bytes()); + super::Name::new_inline(stringify!($ident)); )* }; } diff --git a/crates/mun_syntax/Cargo.toml b/crates/mun_syntax/Cargo.toml index 3d275bf4c..83c18bd9d 100644 --- a/crates/mun_syntax/Cargo.toml +++ b/crates/mun_syntax/Cargo.toml @@ -16,7 +16,7 @@ categories = ["game-development", "mun"] abi = { version = "=0.2.0", path = "../mun_abi", package = "mun_abi" } rowan = "0.6.1" text_unit = { version = "0.1.6", features = ["serde"] } -smol_str = { version = "0.1.12", features = ["serde"] } +smol_str = { version = "0.1.17", features = ["serde"] } unicode-xid = "0.1.0" drop_bomb = "0.1.4"