Skip to content

Commit

Permalink
chore: bump 1.83
Browse files Browse the repository at this point in the history
  • Loading branch information
DaniPopes committed Dec 2, 2024
1 parent e4c5c8e commit 2effc06
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@ jobs:
fail-fast: false
matrix:
os: ["ubuntu-latest", "macos-latest", "windows-latest"]
rust: ["stable", "1.81"]
rust: ["stable", "1.83"]
flags: ["", "--all-features"]
exclude:
# Skip because some features have higher MSRV.
- rust: "1.81" # MSRV
- rust: "1.83" # MSRV
flags: "--all-features"
steps:
- uses: actions/checkout@v4
Expand Down
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ resolver = "2"
[workspace.package]
authors = ["Foundry Maintainers"]
version = "0.12.3"
rust-version = "1.81"
rust-version = "1.83"
readme = "README.md"
license = "MIT OR Apache-2.0"
repository = "https://github.com/foundry-rs/compilers"
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ When updating this, also update:

Foundry Compilers will keep a rolling MSRV (minimum supported rust version) policy of **at
least** 6 months. When increasing the MSRV, the new Rust version must have been
released at least six months ago. The current MSRV is 1.81.0.
released at least six months ago. The current MSRV is 1.83.0.

Note that the MSRV is not increased automatically, and only as part of a minor
release.
Expand Down
2 changes: 1 addition & 1 deletion clippy.toml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
msrv = "1.81"
msrv = "1.83"
6 changes: 3 additions & 3 deletions crates/compilers/src/compilers/solc/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -201,8 +201,8 @@ impl<V: Ord + Copy> Restriction<V> {
///
/// If given None, only returns true if no restrictions are set
pub fn satisfies(&self, value: Option<V>) -> bool {
self.min.map_or(true, |min| value.is_some_and(|v| v >= min))
&& self.max.map_or(true, |max| value.is_some_and(|v| v <= max))
self.min.is_none_or(|min| value.is_some_and(|v| v >= min))
&& self.max.is_none_or(|max| value.is_some_and(|v| v <= max))
}

/// Combines two restrictions into a new one
Expand Down Expand Up @@ -346,7 +346,7 @@ impl CompilerSettings for SolcSettings {
// Ensure that we either don't have min optimizer runs set or that the optimizer is enabled
satisfies &= optimizer_runs
.min
.map_or(true, |min| min == 0 || self.optimizer.enabled.unwrap_or_default());
.is_none_or(|min| min == 0 || self.optimizer.enabled.unwrap_or_default());

satisfies
}
Expand Down
2 changes: 1 addition & 1 deletion crates/compilers/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@ impl<T: ArtifactOutput, C: Compiler> Project<C, T> {
{
let mut contracts = self.collect_contract_names()?;

if contracts.get(target_name).map_or(true, |paths| paths.is_empty()) {
if contracts.get(target_name).is_none_or(|paths| paths.is_empty()) {
return Err(SolcError::msg(format!("No contract found with the name `{target_name}`")));
}
let mut paths = contracts.remove(target_name).unwrap();
Expand Down

0 comments on commit 2effc06

Please sign in to comment.