diff --git a/.github/workflows/ubuntu_x86_64.yml b/.github/workflows/ubuntu_x86_64.yml index 5b8d86519c7..e7a70471944 100644 --- a/.github/workflows/ubuntu_x86_64.yml +++ b/.github/workflows/ubuntu_x86_64.yml @@ -33,7 +33,7 @@ jobs: run: cargo run --locked --release format --check crates/compiler/builtins/roc - name: ensure there are no unused dependencies - run: cargo +nightly-2024-02-03 udeps --all-targets + run: cargo +nightly-2025-09-14 udeps --all-targets - name: zig wasm tests run: cd crates/compiler/builtins/bitcode && ./run-wasm-tests.sh @@ -65,5 +65,5 @@ jobs: #- name: run fuzz tests - ok to merge if this one fails # for now! # run: | - # cargo +nightly-2024-02-03 install --locked cargo-fuzz - # cd crates/compiler/test_syntax/fuzz && cargo +nightly-2024-02-03 fuzz run -j4 fuzz_expr --sanitizer=none -- -dict=dict.txt -max_total_time=60 + # cargo +nightly-2025-09-14 install --locked cargo-fuzz + # cd crates/compiler/test_syntax/fuzz && cargo +nightly-2025-09-14 fuzz run -j4 fuzz_expr --sanitizer=none -- -dict=dict.txt -max_total_time=60 diff --git a/.github/workflows/windows_tests.yml b/.github/workflows/windows_tests.yml index b4910152eee..08ee48392e5 100644 --- a/.github/workflows/windows_tests.yml +++ b/.github/workflows/windows_tests.yml @@ -40,8 +40,8 @@ jobs: cd crates\compiler\builtins\bitcode\ zig build test - - name: install rust nightly 1.77.0 - run: rustup install nightly-2024-02-03 + - name: install rust nightly 1.91.0 + run: rustup install nightly-2025-09-14 - name: set up llvm 18 run: | diff --git a/crates/cli/tests/platform-switching/rust-platform/rust-toolchain.toml b/crates/cli/tests/platform-switching/rust-platform/rust-toolchain.toml index d67979c6af2..f32d71b2ea9 100644 --- a/crates/cli/tests/platform-switching/rust-platform/rust-toolchain.toml +++ b/crates/cli/tests/platform-switching/rust-platform/rust-toolchain.toml @@ -1,9 +1,9 @@ [toolchain] -channel = "1.77.2" +channel = "1.91.1" profile = "default" components = [ # for usages of rust-analyzer or similar tools inside `nix develop` "rust-src" -] \ No newline at end of file +] diff --git a/crates/compiler/build/src/link.rs b/crates/compiler/build/src/link.rs index 2f6ac7639d4..a274798500b 100755 --- a/crates/compiler/build/src/link.rs +++ b/crates/compiler/build/src/link.rs @@ -488,7 +488,7 @@ pub fn rebuild_host( // on windows, we need the nightly toolchain so we can use `-Z export-executable-symbols` // using `+nightly` only works when running cargo through rustup let mut cmd = rustup(); - cmd.args(["run", "nightly-2024-02-03", "cargo"]); + cmd.args(["run", "nightly-2025-09-14", "cargo"]); cmd } else { diff --git a/crates/repl_test/src/wasm.rs b/crates/repl_test/src/wasm.rs index 4fe315172a7..ef09357c9c2 100644 --- a/crates/repl_test/src/wasm.rs +++ b/crates/repl_test/src/wasm.rs @@ -5,7 +5,7 @@ use roc_wasm_interp::{ }; const COMPILER_BYTES: &[u8] = - include_bytes!("../../../target/wasm32-wasi/release-with-lto/roc_repl_wasm.wasm"); + include_bytes!("../../../target/wasm32-wasip1/release-with-lto/roc_repl_wasm.wasm"); struct CompilerDispatcher<'a> { arena: &'a Bump, diff --git a/crates/repl_test/test_wasm.sh b/crates/repl_test/test_wasm.sh index 5d510dccabe..da823b6e1f2 100755 --- a/crates/repl_test/test_wasm.sh +++ b/crates/repl_test/test_wasm.sh @@ -6,10 +6,10 @@ set -euxo pipefail # If we ever decide to do that, one of the cargo processes will need to use the `--target-dir` option. # We need to clear RUSTFLAGS for this command, as CI sets normally some flags that are specific to CPU targets. -# Tests target wasm32-wasi instead of wasm32-unknown-unknown, so that we can debug with println! and dbg +# Tests target wasm32-wasip1 instead of wasm32-unknown-unknown, so that we can debug with println! and dbg # This has to be built with lto for now. If we do not use lto, it will pull in system calls we don't yet support. # TODO: Add system calls to our wasi interp so that this can just be built in release without lto. -RUSTFLAGS="" cargo build --locked --profile release-with-lto --target wasm32-wasi -p roc_repl_wasm --no-default-features --features wasi_test +RUSTFLAGS="" cargo build --locked --profile release-with-lto --target wasm32-wasip1 -p roc_repl_wasm --no-default-features --features wasi_test # Build & run the test code on *native* target, not WebAssembly cargo test --locked --release -p repl_test --features wasm $@ diff --git a/flake.lock b/flake.lock index f3968fd31ef..3e36779474f 100644 --- a/flake.lock +++ b/flake.lock @@ -3,11 +3,11 @@ "flake-compat": { "flake": false, "locked": { - "lastModified": 1733328505, - "narHash": "sha256-NeCCThCEP3eCl2l/+27kNNK7QrwZB1IJCrXfrbv5oqU=", + "lastModified": 1761588595, + "narHash": "sha256-XKUZz9zewJNUj46b4AJdiRZJAvSZ0Dqj2BNfXvFlJC4=", "owner": "edolstra", "repo": "flake-compat", - "rev": "ff81ac966bb2cae68946d5ed5fc4994f96d0ffec", + "rev": "f387cd2afec9419c8ee37694406ca490c3f34ee5", "type": "github" }, "original": { @@ -36,17 +36,17 @@ }, "nixpkgs": { "locked": { - "lastModified": 1722403750, - "narHash": "sha256-tRmn6UiFAPX0m9G1AVcEPjWEOc9BtGsxGcs7Bz3MpsM=", + "lastModified": 1763283776, + "narHash": "sha256-Y7TDFPK4GlqrKrivOcsHG8xSGqQx3A6c+i7novT85Uk=", "owner": "nixos", "repo": "nixpkgs", - "rev": "184957277e885c06a505db112b35dfbec7c60494", + "rev": "50a96edd8d0db6cc8db57dab6bb6d6ee1f3dc49a", "type": "github" }, "original": { "owner": "nixos", "repo": "nixpkgs", - "rev": "184957277e885c06a505db112b35dfbec7c60494", + "rev": "50a96edd8d0db6cc8db57dab6bb6d6ee1f3dc49a", "type": "github" } }, @@ -65,11 +65,11 @@ ] }, "locked": { - "lastModified": 1736303309, - "narHash": "sha256-IKrk7RL+Q/2NC6+Ql6dwwCNZI6T6JH2grTdJaVWHF0A=", + "lastModified": 1763347184, + "narHash": "sha256-6QH8hpCYJxifvyHEYg+Da0BotUn03BwLIvYo3JAxuqQ=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "a0b81d4fa349d9af1765b0f0b4a899c13776f706", + "rev": "08895cce80433978d5bfd668efa41c5e24578cbd", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index 9ae6ac0b78a..cd4800bb676 100644 --- a/flake.nix +++ b/flake.nix @@ -3,7 +3,7 @@ inputs = { nixpkgs.url = - "github:nixos/nixpkgs?rev=184957277e885c06a505db112b35dfbec7c60494"; + "github:nixos/nixpkgs?rev=50a96edd8d0db6cc8db57dab6bb6d6ee1f3dc49a"; # rust from nixpkgs has some libc problems, this is patched in the rust-overlay rust-overlay = { diff --git a/nix/compile-deps.nix b/nix/compile-deps.nix index 8f8adb56d0b..d803a495a92 100644 --- a/nix/compile-deps.nix +++ b/nix/compile-deps.nix @@ -1,6 +1,6 @@ { pkgs }: let - zigPkg = pkgs.zig; + zigPkg = pkgs.zig_0_13; llvmPkgs = pkgs.llvm_18; llvmVersion = builtins.splitVersion llvmPkgs.release_version; llvmMajorMinorStr = builtins.elemAt llvmVersion 0 + builtins.elemAt llvmVersion 1; diff --git a/rust-toolchain.toml b/rust-toolchain.toml index 82729fe7394..f3451b23dc6 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -1,19 +1,18 @@ [toolchain] # How to update version: # - update `channel = "RUST_VERSION"` -# - update `channel = "RUST_VERSION"` in examples/platform-switching/rust-platform/rust-toolchain.toml -# - update `channel = "RUST_VERSION"` in examples/glue/rust-platform/rust-toolchain.toml +# - update `channel = "RUST_VERSION"` in crates/cli/tests/platform-switching/rust-platform/rust-toolchain.toml # - to update the nightly version: -# - Find the latest nightly release that matches RUST_VERSION here: https://github.com/oxalica/rust-overlay/tree/master/manifests/nightly/2024 +# - Find the latest nightly release that matches RUST_VERSION here: https://github.com/oxalica/rust-overlay/tree/master/manifests/nightly/2025 # - update `channel = "nightly-OLD_DATE"` below # - update nightly-OLD_DATE in .github/workflows/ubuntu_x86_64.yml # - update nightly-OLD_DATE in .github/workflows/windows_tests.yml # - update nightly-OLD_DATE in .github/workflows/windows_release_build.yml # - update nightly-OLD_DATE in crates/compiler/build/src/link.rs -channel = "1.77.2" # check ^^^ when changing this +channel = "1.91.1" # check ^^^ when changing this # -# channel = "nightly-2024-02-03" # 1.77.0 nightly to be able to use unstable features +# channel = "nightly-2025-09-14" # 1.91.0 nightly to be able to use unstable features profile = "default" components = [ # for usages of rust-analyzer or similar tools inside `nix develop` @@ -21,6 +20,6 @@ components = [ ] targets = [ - "wasm32-wasi", # for test_wasm.sh + "wasm32-wasip1", # for test_wasm.sh "wasm32-unknown-unknown", # for repl_wasm ]