From 4126e2ebda012e42860394a34832bfb96a096a24 Mon Sep 17 00:00:00 2001 From: Kyryl R Date: Tue, 6 Jan 2026 16:31:48 +0200 Subject: [PATCH 1/3] fix ffi for platform-specific uint_fast types for macOS and Android --- simplicity-sys/src/ffi.rs | 34 ++++++++++++++++++++++++++-------- 1 file changed, 26 insertions(+), 8 deletions(-) diff --git a/simplicity-sys/src/ffi.rs b/simplicity-sys/src/ffi.rs index ae94d2c9..d2e901d5 100644 --- a/simplicity-sys/src/ffi.rs +++ b/simplicity-sys/src/ffi.rs @@ -19,18 +19,36 @@ pub type c_int = i32; pub type c_uint = u32; pub type c_size_t = usize; pub type c_uint_fast8_t = u8; -#[cfg(all( - any(target_arch = "wasm32", target_arch = "aarch64"), - not(target_os = "windows") -))] +#[cfg(any(target_os = "macos", target_os = "ios"))] pub type c_uint_fast16_t = u16; -#[cfg(target_os = "windows")] +#[cfg(any(target_os = "windows", target_os = "android"))] pub type c_uint_fast16_t = u32; -#[cfg(not(any(target_arch = "wasm32", target_arch = "aarch64", target_os = "windows")))] +#[cfg(target_arch = "wasm32")] +pub type c_uint_fast16_t = u16; +#[cfg(not(any( + target_os = "macos", + target_os = "ios", + target_os = "windows", + target_os = "android", + target_arch = "wasm32" +)))] pub type c_uint_fast16_t = usize; -#[cfg(any(target_arch = "wasm32", target_arch = "aarch64", target_os = "windows"))] + +#[cfg(any( + target_os = "macos", + target_os = "ios", + target_os = "windows", + target_os = "android", + target_arch = "wasm32" +))] pub type c_uint_fast32_t = u32; -#[cfg(not(any(target_arch = "wasm32", target_arch = "aarch64", target_os = "windows")))] +#[cfg(not(any( + target_os = "macos", + target_os = "ios", + target_os = "windows", + target_os = "android", + target_arch = "wasm32" +)))] pub type c_uint_fast32_t = usize; #[cfg(target_arch = "wasm32")] pub type c_uint_fast64_t = u64; From 7a77539cb9c1ce22d3e465de7367f738f4f18950 Mon Sep 17 00:00:00 2001 From: Kyryl R Date: Tue, 6 Jan 2026 16:57:36 +0200 Subject: [PATCH 2/3] Bump simplicity-sys version to 0.6.1 --- Cargo-recent.lock | 4 ++-- Cargo.toml | 4 ++-- simplicity-sys/Cargo.toml | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Cargo-recent.lock b/Cargo-recent.lock index 30221a36..c56d0661 100644 --- a/Cargo-recent.lock +++ b/Cargo-recent.lock @@ -503,7 +503,7 @@ dependencies = [ "miniscript", "santiago", "serde", - "simplicity-sys 0.6.0", + "simplicity-sys 0.6.1", ] [[package]] @@ -518,7 +518,7 @@ dependencies = [ [[package]] name = "simplicity-sys" -version = "0.6.0" +version = "0.6.1" dependencies = [ "bitcoin_hashes", "cc", diff --git a/Cargo.toml b/Cargo.toml index f63bebaa..076b1f9a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -30,14 +30,14 @@ ghost-cell = { version = "0.2.6", default-features = false } hashes = { package = "bitcoin_hashes", version = "0.14" } hex = { package = "hex-conservative", version = "0.2.1" } santiago = "1.3" -simplicity-sys = { version = "0.6.0", path = "./simplicity-sys" } +simplicity-sys = { version = "0.6.1", path = "./simplicity-sys" } serde = { version = "1.0.103", features = ["derive"], optional = true } [target.wasm32-unknown-unknown.dependencies] getrandom = { version = "0.2", features = ["js"] } [dev-dependencies] -simplicity-sys = { version = "0.6.0", path = "./simplicity-sys", features = [ +simplicity-sys = { version = "0.6.1", path = "./simplicity-sys", features = [ "test-utils", ] } diff --git a/simplicity-sys/Cargo.toml b/simplicity-sys/Cargo.toml index 7f892e26..622949e0 100644 --- a/simplicity-sys/Cargo.toml +++ b/simplicity-sys/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "simplicity-sys" -version = "0.6.0" +version = "0.6.1" license = "CC0-1.0" homepage = "https://github.com/BlockstreamResearch/rust-simplicity/" repository = "https://github.com/BlockstreamResearch/rust-simplicity/" From 117b90c3068cd6bdcc99fba6bd49be75453247d1 Mon Sep 17 00:00:00 2001 From: Kyryl R Date: Tue, 6 Jan 2026 17:44:55 +0200 Subject: [PATCH 3/3] Bump simplicity-lang version to 0.7.1 --- Cargo-recent.lock | 6 +++--- Cargo.toml | 2 +- README.md | 2 +- fuzz/Cargo.toml | 2 +- fuzz/generate-files.sh | 2 +- simpcli/Cargo.toml | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Cargo-recent.lock b/Cargo-recent.lock index c56d0661..c074ff84 100644 --- a/Cargo-recent.lock +++ b/Cargo-recent.lock @@ -461,7 +461,7 @@ checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" name = "simpcli" version = "0.3.0" dependencies = [ - "simplicity-lang 0.7.0", + "simplicity-lang 0.7.1", ] [[package]] @@ -471,7 +471,7 @@ dependencies = [ "base64 0.22.1", "libfuzzer-sys", "simplicity-lang 0.3.1", - "simplicity-lang 0.7.0", + "simplicity-lang 0.7.1", ] [[package]] @@ -491,7 +491,7 @@ dependencies = [ [[package]] name = "simplicity-lang" -version = "0.7.0" +version = "0.7.1" dependencies = [ "bitcoin", "bitcoin_hashes", diff --git a/Cargo.toml b/Cargo.toml index 076b1f9a..1bc0991d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "simplicity-lang" -version = "0.7.0" +version = "0.7.1" authors = ["Andrew Poelstra "] license = "CC0-1.0" homepage = "https://github.com/BlockstreamResearch/rust-simplicity/" diff --git a/README.md b/README.md index ee3e226f..fa0f8ee2 100644 --- a/README.md +++ b/README.md @@ -50,7 +50,7 @@ To use rust-simplicity, this to your Cargo.toml: ```toml [dependencies] -simplicity-lang = "0.6" +simplicity-lang = "0.7" ``` ## Quick Start diff --git a/fuzz/Cargo.toml b/fuzz/Cargo.toml index 4135e812..f56954f2 100644 --- a/fuzz/Cargo.toml +++ b/fuzz/Cargo.toml @@ -16,7 +16,7 @@ path = "fuzz_lib/lib.rs" libfuzzer-sys = "0.4" # We shouldn't need an explicit version on the next line, but Andrew's tools # choke on it otherwise. See https://github.com/nix-community/crate2nix/issues/373 -simplicity-lang = { path = "..", features = ["test-utils"], version = "0.7.0" } +simplicity-lang = { path = "..", features = ["test-utils"], version = "0.7.1" } old_simplicity = { package = "simplicity-lang", version = "0.3.1", default-features = false } [dev-dependencies] diff --git a/fuzz/generate-files.sh b/fuzz/generate-files.sh index 00134400..f1e45444 100755 --- a/fuzz/generate-files.sh +++ b/fuzz/generate-files.sh @@ -27,7 +27,7 @@ path = "fuzz_lib/lib.rs" libfuzzer-sys = "0.4" # We shouldn't need an explicit version on the next line, but Andrew's tools # choke on it otherwise. See https://github.com/nix-community/crate2nix/issues/373 -simplicity-lang = { path = "..", features = ["test-utils"], version = "0.6.0" } +simplicity-lang = { path = "..", features = ["test-utils"], version = "0.7.1" } old_simplicity = { package = "simplicity-lang", version = "0.3.1", default-features = false } [dev-dependencies] diff --git a/simpcli/Cargo.toml b/simpcli/Cargo.toml index 1f9e5eb7..88a68ae1 100644 --- a/simpcli/Cargo.toml +++ b/simpcli/Cargo.toml @@ -7,7 +7,7 @@ edition = "2018" [dependencies] # todo add lexopt for command line parsing -simplicity-lang = { version = "0.7.0", path = "..", features = [ "base64", "serde", "elements" ] } +simplicity-lang = { version = "0.7.1", path = "..", features = [ "base64", "serde", "elements" ] } [[bin]] name = "simpcli"