Skip to content

Commit 837b6e4

Browse files
authored
chore: cleanup workspace deps (foundry-rs#158)
sort + rm a few
1 parent 908a83a commit 837b6e4

File tree

4 files changed

+40
-45
lines changed

4 files changed

+40
-45
lines changed

Cargo.toml

Lines changed: 20 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ license = "MIT OR Apache-2.0"
1111
repository = "https://github.com/foundry-rs/compilers"
1212
homepage = "https://github.com/foundry-rs/compilers"
1313
documentation = "https://docs.rs/foundry-compilers"
14-
description = "Utilities for working with solidity compilers, namely solc"
14+
description = "Utilities for working with EVM language compilers"
1515
keywords = ["foundry", "solidity", "solc", "ethereum", "ethers"]
1616
edition = "2021"
1717
exclude = [".github/", "scripts/", "test-data/"]
@@ -31,27 +31,33 @@ unused-must-use = "deny"
3131
all = "warn"
3232

3333
[workspace.dependencies]
34+
foundry-compilers = { path = "crates/compilers", version = "0.8.0" }
35+
foundry-compilers-artifacts = { path = "crates/artifacts/artifacts", version = "0.8.0" }
3436
foundry-compilers-artifacts-solc = { path = "crates/artifacts/solc", version = "0.8.0" }
3537
foundry-compilers-artifacts-vyper = { path = "crates/artifacts/vyper", version = "0.8.0" }
36-
foundry-compilers-artifacts = { path = "crates/artifacts/artifacts", version = "0.8.0" }
3738
foundry-compilers-core = { path = "crates/core", version = "0.8.0" }
38-
serde = { version = "1", features = ["derive", "rc"] }
39-
semver = { version = "1.0", features = ["serde"] }
40-
serde_json = "1.0"
41-
alloy-primitives = { version = "0.7", features = ["serde", "rand"] }
39+
4240
alloy-json-abi = { version = "0.7", features = ["serde_json"] }
43-
tracing = "0.1"
44-
rayon = "1.8"
45-
thiserror = "1"
46-
regex = "1.10"
47-
path-slash = "0.2"
41+
alloy-primitives = { version = "0.7", features = ["serde", "rand"] }
42+
cfg-if = "1.0"
43+
dunce = "1.0"
4844
md-5 = "0.10"
49-
yansi = "1.0.1"
45+
memmap2 = "0.9"
5046
once_cell = "1.19"
51-
svm = { package = "svm-rs", version = "0.5", default-features = false }
52-
solang-parser = { version = "=0.3.3", default-features = false }
47+
path-slash = "0.2"
48+
rayon = "1.8"
49+
regex = "1.10"
50+
semver = { version = "1.0", features = ["serde"] }
51+
serde = { version = "1", features = ["derive", "rc"] }
52+
serde_json = "1.0"
5353
similar-asserts = "1"
54+
solang-parser = { version = "=0.3.3", default-features = false }
55+
svm = { package = "svm-rs", version = "0.5", default-features = false }
5456
tempfile = "3.9"
57+
thiserror = "1"
58+
tracing = "0.1"
59+
walkdir = "2.5"
60+
yansi = "1.0"
5561

5662
# async
5763
futures-util = "0.3"

crates/artifacts/solc/Cargo.toml

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,20 +17,19 @@ workspace = true
1717
[dependencies]
1818
foundry-compilers-core.workspace = true
1919

20-
serde.workspace = true
21-
semver.workspace = true
22-
serde_json.workspace = true
23-
tracing.workspace = true
24-
alloy-primitives.workspace = true
2520
alloy-json-abi.workspace = true
21+
alloy-primitives.workspace = true
22+
futures-util = { workspace = true, optional = true }
23+
md-5.workspace = true
2624
rayon.workspace = true
25+
semver.workspace = true
26+
serde_json.workspace = true
27+
serde.workspace = true
2728
thiserror.workspace = true
28-
md-5.workspace = true
29-
yansi.workspace = true
30-
futures-util = { workspace = true, optional = true }
3129
tokio = { workspace = true, optional = true }
32-
33-
walkdir = "2.4"
30+
tracing.workspace = true
31+
walkdir.workspace = true
32+
yansi.workspace = true
3433

3534
[target.'cfg(windows)'.dependencies]
3635
path-slash.workspace = true

crates/core/Cargo.toml

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -15,27 +15,26 @@ exclude.workspace = true
1515
workspace = true
1616

1717
[dependencies]
18-
thiserror.workspace = true
19-
semver.workspace = true
20-
serde.workspace = true
21-
serde_json.workspace = true
22-
regex.workspace = true
23-
path-slash.workspace = true
2418
alloy-primitives.workspace = true
19+
cfg-if.workspace = true
20+
dunce.workspace = true
21+
memmap2.workspace = true
2522
once_cell.workspace = true
23+
path-slash.workspace = true
24+
regex.workspace = true
25+
semver.workspace = true
26+
serde_json.workspace = true
27+
serde.workspace = true
28+
thiserror.workspace = true
29+
walkdir.workspace = true
30+
2631
svm = { workspace = true, optional = true }
2732
tokio = { workspace = true, optional = true }
2833

29-
walkdir = "2.4"
30-
dunce = "1.0"
31-
memmap2 = "0.9"
32-
cfg-if = "1.0.0"
33-
3434
tempfile = { workspace = true, optional = true }
3535
fs_extra = { version = "1.3", optional = true }
3636

3737
[dev-dependencies]
38-
solang-parser.workspace = true
3938
tempfile.workspace = true
4039

4140
[features]

crates/core/src/utils.rs

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -663,7 +663,6 @@ pub fn mkdir_or_touch(tmp: &std::path::Path, paths: &[&str]) {
663663
#[cfg(test)]
664664
mod tests {
665665
use super::*;
666-
use solang_parser::pt::SourceUnitPart;
667666
use std::fs::{create_dir_all, File};
668667

669668
#[test]
@@ -740,15 +739,7 @@ mod tests {
740739
fn can_parse_curly_bracket_imports() {
741740
let s =
742741
r#"import {ReentrancyGuard} from "@openzeppelin/contracts/utils/ReentrancyGuard.sol";"#;
743-
744-
let (unit, _) = solang_parser::parse(s, 0).unwrap();
745-
assert_eq!(unit.0.len(), 1);
746-
match unit.0[0] {
747-
SourceUnitPart::ImportDirective(_) => {}
748-
_ => unreachable!("failed to parse import"),
749-
}
750742
let imports: Vec<_> = find_import_paths(s).map(|m| m.as_str()).collect();
751-
752743
assert_eq!(imports, vec!["@openzeppelin/contracts/utils/ReentrancyGuard.sol"])
753744
}
754745

0 commit comments

Comments
 (0)