Skip to content

Use revive crate for MemoryConfig defaults #32

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jun 2, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ jobs:
fail-fast: false
matrix:
os: ["ubuntu-latest", "macos-latest", "windows-latest"]
rust: ["stable", "1.83"]
rust: ["stable", "1.87"]
flags: ["", "--all-features"]
exclude:
# Skip because some features have higher MSRV.
- rust: "1.83" # MSRV
- rust: "1.87" # MSRV
flags: "--all-features"
steps:
- uses: actions/checkout@v4
Expand Down
64 changes: 64 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ foundry-compilers-artifacts-vyper = { path = "crates/artifacts/vyper", version =
foundry-compilers-artifacts-resolc = { path = "crates/artifacts/resolc", version = "0.14.0" }
foundry-compilers-core = { path = "crates/core", version = "0.14.0" }
rvm = { package = "rvm-rs", version = "0.0.2", default-features = false }
revive-solc-json-interface = { version = "0.1", default-features = false }

alloy-json-abi = { version = "0.8", features = ["serde_json"] }
alloy-primitives = { version = "0.8", features = ["serde", "rand"] }
Expand Down
2 changes: 1 addition & 1 deletion crates/compilers/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ sha2 = { version = "0.10", default-features = false, optional = true }

# rvm
rvm = { workspace = true, default-features = false }

revive-solc-json-interface = { workspace = true, default-features = false }

[dev-dependencies]
tracing-subscriber = { version = "0.3", default-features = false, features = [
Expand Down
4 changes: 3 additions & 1 deletion crates/compilers/src/compilers/resolc/input.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ use foundry_compilers_artifacts::{
SolcLanguage, Source, Sources,
};
use foundry_compilers_core::utils::strip_prefix_owned;
use revive_solc_json_interface::SolcStandardJsonInputSettingsPolkaVMMemory;
use semver::Version;
use serde::{Deserialize, Serialize};
use std::{collections::HashSet, path::Path};
Expand Down Expand Up @@ -36,7 +37,8 @@ pub struct MemoryConfig {

impl Default for MemoryConfig {
fn default() -> Self {
Self { heap_size: 64 * 1024, stack_size: 32 * 1024 }
let mem = SolcStandardJsonInputSettingsPolkaVMMemory::default();
Self { heap_size: mem.heap_size, stack_size: mem.stack_size }
}
}

Expand Down