Skip to content

Commit cc6f06c

Browse files
authored
Downgraded SmolStr lib. (#7405)
1 parent 13ffe3a commit cc6f06c

File tree

3 files changed

+5
-21
lines changed

3 files changed

+5
-21
lines changed

Cargo.lock

Lines changed: 2 additions & 18 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ serde = { version = "1.0.217", default-features = false, features = ["derive"] }
129129
serde_json = "1.0.138"
130130
sha2 = "0.10.8"
131131
sha3 = "0.10.8"
132-
smol_str = { version = "0.3.2", features = ["serde"] }
132+
smol_str = { version = "0.2.0", features = ["serde"] }
133133
starknet-types-core = { version = "0.1.7", features = [
134134
"hash",
135135
"prime-bigint",

crates/cairo-lang-filesystem/src/ids.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ impl Directory {
192192
/// the file system. These are ids/paths to them.
193193
pub fn file(&self, db: &dyn FilesGroup, name: SmolStr) -> FileId {
194194
match self {
195-
Directory::Real(path) => FileId::new(db, path.join(&name)),
195+
Directory::Real(path) => FileId::new(db, path.join(name.as_str())),
196196
Directory::Virtual { files, dirs: _ } => files
197197
.get(&name)
198198
.copied()
@@ -204,7 +204,7 @@ impl Directory {
204204
/// the file system. These are ids/paths to them.
205205
pub fn subdir(&self, name: SmolStr) -> Directory {
206206
match self {
207-
Directory::Real(path) => Directory::Real(path.join(&name)),
207+
Directory::Real(path) => Directory::Real(path.join(name.as_str())),
208208
Directory::Virtual { files: _, dirs } => {
209209
if let Some(dir) = dirs.get(&name) {
210210
dir.as_ref().clone()

0 commit comments

Comments
 (0)