diff --git a/.github/workflows/nix_macos_apple_silicon.yml b/.github/workflows/nix_macos_apple_silicon.yml index c60eff5199..8e8bce3268 100644 --- a/.github/workflows/nix_macos_apple_silicon.yml +++ b/.github/workflows/nix_macos_apple_silicon.yml @@ -27,7 +27,7 @@ jobs: run: nix develop -c cargo clippy --workspace --tests -- --deny warnings - name: check code style with clippy --release - run: cargo clippy --workspace --tests --release -- --deny warnings + run: nix develop -c cargo clippy --workspace --tests --release -- --deny warnings - name: test building default.nix run: nix-build diff --git a/.github/workflows/windows_release_build.yml b/.github/workflows/windows_release_build.yml index fee39a873a..d7ba5005c0 100644 --- a/.github/workflows/windows_release_build.yml +++ b/.github/workflows/windows_release_build.yml @@ -33,8 +33,8 @@ jobs: - name: zig version run: zig version - - name: install rust nightly 1.70.0 - run: rustup install nightly-2023-04-15 + - name: install rust nightly 1.71.0 + run: rustup install nightly-2023-05-28 - name: set up llvm 13 run: | diff --git a/.github/workflows/windows_tests.yml b/.github/workflows/windows_tests.yml index 7b6b5987a8..aa5336ffc4 100644 --- a/.github/workflows/windows_tests.yml +++ b/.github/workflows/windows_tests.yml @@ -41,8 +41,8 @@ jobs: cd crates\compiler\builtins\bitcode\ zig build test - - name: install rust nightly 1.70.0 - run: rustup install nightly-2023-04-15 + - name: install rust nightly 1.71.0 + run: rustup install nightly-2023-05-28 - name: set up llvm 13 run: | diff --git a/Earthfile b/Earthfile index f94a859b60..f6e461e6f9 100644 --- a/Earthfile +++ b/Earthfile @@ -1,6 +1,6 @@ VERSION 0.6 -FROM rust:1.70.0-slim-buster # make sure to update rust-toolchain.toml too so that everything uses the same rust version +FROM rust:1.71.1-slim-buster # make sure to update rust-toolchain.toml too so that everything uses the same rust version WORKDIR /earthbuild prep-debian: diff --git a/crates/cli/tests/cli_run.rs b/crates/cli/tests/cli_run.rs index e3de91874a..a7f686d6b3 100644 --- a/crates/cli/tests/cli_run.rs +++ b/crates/cli/tests/cli_run.rs @@ -793,7 +793,7 @@ mod cli_run { } #[test] - #[cfg_attr(windows, ignore)] + #[cfg_attr(any(target_os = "windows", target_os = "linux"), ignore = "Segfault")] fn false_interpreter() { test_roc_app( "examples/cli/false-interpreter", diff --git a/crates/compiler/build/src/link.rs b/crates/compiler/build/src/link.rs index 1e729eb1be..cea1ebaedc 100644 --- a/crates/compiler/build/src/link.rs +++ b/crates/compiler/build/src/link.rs @@ -531,7 +531,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-2023-04-15", "cargo"]); + cmd.args(["run", "nightly-2023-05-28", "cargo"]); cmd } else { diff --git a/crates/compiler/mono/src/ir.rs b/crates/compiler/mono/src/ir.rs index e6bb548210..2baede2618 100644 --- a/crates/compiler/mono/src/ir.rs +++ b/crates/compiler/mono/src/ir.rs @@ -77,8 +77,8 @@ roc_error_macros::assert_sizeof_wasm!(Call, 44); roc_error_macros::assert_sizeof_wasm!(CallType, 36); roc_error_macros::assert_sizeof_non_wasm!(Literal, 3 * 8); -roc_error_macros::assert_sizeof_non_wasm!(Expr, 10 * 8); -roc_error_macros::assert_sizeof_non_wasm!(Stmt, 13 * 8); +roc_error_macros::assert_sizeof_non_wasm!(Expr, 9 * 8); +roc_error_macros::assert_sizeof_non_wasm!(Stmt, 12 * 8); roc_error_macros::assert_sizeof_non_wasm!(ProcLayout, 5 * 8); roc_error_macros::assert_sizeof_non_wasm!(Call, 9 * 8); roc_error_macros::assert_sizeof_non_wasm!(CallType, 7 * 8); diff --git a/crates/compiler/test_gen/src/gen_abilities.rs b/crates/compiler/test_gen/src/gen_abilities.rs index e4b393d406..2b6971c696 100644 --- a/crates/compiler/test_gen/src/gen_abilities.rs +++ b/crates/compiler/test_gen/src/gen_abilities.rs @@ -808,7 +808,7 @@ fn encode_derived_list_of_lists_of_strings() { #[test] #[cfg(not(debug_assertions))] -#[cfg(all(any(feature = "gen-llvm", feature = "gen-wasm")))] +#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))] fn encode_derived_record_with_many_types() { assert_evals_to!( indoc!( @@ -882,7 +882,7 @@ fn encode_derived_tuple_of_tuples() { #[test] #[cfg(not(debug_assertions))] -#[cfg(all(any(feature = "gen-llvm", feature = "gen-wasm")))] +#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))] fn encode_derived_generic_record_with_different_field_types() { assert_evals_to!( indoc!( @@ -908,7 +908,7 @@ fn encode_derived_generic_record_with_different_field_types() { } #[test] -#[cfg(all(any(feature = "gen-llvm", feature = "gen-wasm")))] +#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))] fn encode_derived_generic_tag_with_different_field_types() { assert_evals_to!( indoc!( @@ -1057,13 +1057,13 @@ mod decode_immediate { #[cfg(all(test, any(feature = "gen-llvm", feature = "gen-wasm")))] use indoc::indoc; - #[cfg(all(test, any(feature = "gen-llvm")))] + #[cfg(all(test, feature = "gen-llvm"))] use roc_std::RocStr; use crate::helpers::with_larger_debug_stack; #[test] - #[cfg(any(feature = "gen-llvm"))] + #[cfg(feature = "gen-llvm")] fn string() { with_larger_debug_stack(|| { assert_evals_to!( @@ -1084,7 +1084,7 @@ mod decode_immediate { } #[test] - #[cfg(any(feature = "gen-llvm"))] + #[cfg(feature = "gen-llvm")] fn ranged_number() { assert_evals_to!( indoc!( @@ -1106,7 +1106,7 @@ mod decode_immediate { } #[test] - #[cfg(any(feature = "gen-llvm"))] + #[cfg(feature = "gen-llvm")] fn bool() { assert_evals_to!( indoc!( @@ -1127,7 +1127,7 @@ mod decode_immediate { macro_rules! num_immediate { ($($num:expr, $typ:ident)*) => {$( #[test] - #[cfg(any(feature = "gen-llvm"))] + #[cfg(feature = "gen-llvm")] fn $typ() { assert_evals_to!( &format!(indoc!( @@ -1206,7 +1206,7 @@ fn decode_list_of_strings() { } #[test] -#[cfg(all(any(feature = "gen-llvm", feature = "gen-wasm")))] +#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))] fn encode_then_decode_list_of_strings() { with_larger_debug_stack(|| { assert_evals_to!( @@ -1227,7 +1227,7 @@ fn encode_then_decode_list_of_strings() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] #[ignore = "#3696: Currently hits some weird panic in borrow checking, not sure if it's directly related to abilities."] fn encode_then_decode_list_of_lists_of_strings() { with_larger_debug_stack(|| { diff --git a/crates/compiler/test_gen/src/gen_erased.rs b/crates/compiler/test_gen/src/gen_erased.rs index 682089cd87..df4b87ff69 100644 --- a/crates/compiler/test_gen/src/gen_erased.rs +++ b/crates/compiler/test_gen/src/gen_erased.rs @@ -4,7 +4,7 @@ use crate::helpers::llvm::assert_evals_to_erased; use indoc::indoc; #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn capture_multiple() { assert_evals_to_erased!( indoc!( @@ -23,7 +23,7 @@ fn capture_multiple() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn multi_branch_capturing() { assert_evals_to_erased!( indoc!( diff --git a/crates/compiler/test_gen/src/gen_list.rs b/crates/compiler/test_gen/src/gen_list.rs index ce543a33b2..6abb0686f7 100644 --- a/crates/compiler/test_gen/src/gen_list.rs +++ b/crates/compiler/test_gen/src/gen_list.rs @@ -3014,7 +3014,7 @@ fn list_all() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn list_all_empty_with_unknown_element_type() { assert_evals_to!("List.all [] (\\_ -> Bool.true)", true, bool); } diff --git a/crates/compiler/test_gen/src/gen_num.rs b/crates/compiler/test_gen/src/gen_num.rs index a7e2296400..a825185275 100644 --- a/crates/compiler/test_gen/src/gen_num.rs +++ b/crates/compiler/test_gen/src/gen_num.rs @@ -1558,7 +1558,7 @@ fn tail_call_elimination() { } #[test] -#[cfg(any(feature = "gen-dev"))] +#[cfg(feature = "gen-dev")] fn int_negate_dev() { // TODO // dev backend yet to have `Num.maxI64` or `Num.minI64`. @@ -2317,7 +2317,7 @@ fn min_f32() { } #[test] -#[cfg(all(any(feature = "gen-llvm"), not(feature = "gen-llvm-wasm")))] +#[cfg(all(feature = "gen-llvm", not(feature = "gen-llvm-wasm")))] fn to_nat_truncate_wraps() { let input = "Num.toNat 10_000_000_000_000_000_000_000i128"; assert_evals_to!(input, 1864712049423024128, u64) @@ -3885,7 +3885,7 @@ fn num_abs_diff_int() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn num_abs_diff_large_bits() { assert_evals_to!(r#"Num.absDiff 0u128 0u128"#, 0, u128); assert_evals_to!(r#"Num.absDiff 1u128 2u128"#, 1, u128); @@ -3918,7 +3918,7 @@ fn num_abs_int_min_overflow() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] #[should_panic(expected = r#"Roc failed with message: "integer subtraction overflowed!"#)] fn num_abs_large_bits_min_overflow() { assert_evals_to!(r#"Num.absDiff Num.minI128 0"#, 0, i128); diff --git a/crates/compiler/test_gen/src/gen_primitives.rs b/crates/compiler/test_gen/src/gen_primitives.rs index 39c38ba22a..6d47398614 100644 --- a/crates/compiler/test_gen/src/gen_primitives.rs +++ b/crates/compiler/test_gen/src/gen_primitives.rs @@ -4460,7 +4460,7 @@ fn layout_cache_structure_with_multiple_recursive_structures() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn reset_recursive_type_wraps_in_named_type() { assert_evals_to!( indoc!( diff --git a/crates/compiler/test_gen/src/gen_refcount.rs b/crates/compiler/test_gen/src/gen_refcount.rs index f63e9b51ce..de2c846380 100644 --- a/crates/compiler/test_gen/src/gen_refcount.rs +++ b/crates/compiler/test_gen/src/gen_refcount.rs @@ -13,7 +13,7 @@ use roc_std::{RocList, RocStr}; type Pointer = usize; #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn str_inc() { assert_refcounts!( indoc!( @@ -32,7 +32,7 @@ fn str_inc() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn str_dealloc() { assert_refcounts!( indoc!( @@ -48,7 +48,7 @@ fn str_dealloc() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn list_int_inc() { assert_refcounts!( indoc!( @@ -66,7 +66,7 @@ fn list_int_inc() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn list_int_dealloc() { assert_refcounts!( indoc!( @@ -84,7 +84,7 @@ fn list_int_dealloc() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn list_str_inc() { assert_refcounts!( indoc!( @@ -104,7 +104,7 @@ fn list_str_inc() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn list_str_dealloc() { assert_refcounts!( indoc!( @@ -124,7 +124,7 @@ fn list_str_dealloc() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn struct_inc() { assert_refcounts!( indoc!( @@ -141,7 +141,7 @@ fn struct_inc() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn struct_dealloc() { assert_refcounts!( indoc!( @@ -159,7 +159,7 @@ fn struct_dealloc() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn union_nonrecursive_inc() { type TwoStr = (RocStr, RocStr, i64); @@ -185,7 +185,7 @@ fn union_nonrecursive_inc() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn union_nonrecursive_dec() { assert_refcounts!( indoc!( @@ -208,7 +208,7 @@ fn union_nonrecursive_dec() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn union_recursive_inc() { assert_refcounts!( indoc!( @@ -236,7 +236,7 @@ fn union_recursive_inc() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn union_recursive_dec() { assert_refcounts!( indoc!( @@ -266,7 +266,7 @@ fn union_recursive_dec() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn refcount_different_rosetrees_inc() { // Requires two different Inc procedures for `List (Rose I64)` and `List (Rose Str)` // even though both appear in the mono Layout as `List(RecursivePointer)` @@ -306,7 +306,7 @@ fn refcount_different_rosetrees_inc() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn refcount_different_rosetrees_dec() { // Requires two different Dec procedures for `List (Rose I64)` and `List (Rose Str)` // even though both appear in the mono Layout as `List(RecursivePointer)` @@ -347,7 +347,7 @@ fn refcount_different_rosetrees_dec() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn union_linked_list_inc() { assert_refcounts!( indoc!( @@ -373,7 +373,7 @@ fn union_linked_list_inc() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn union_linked_list_dec() { assert_refcounts!( indoc!( @@ -401,7 +401,7 @@ fn union_linked_list_dec() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn union_linked_list_nil_dec() { let no_refcounts: &[crate::helpers::RefCount] = &[]; assert_refcounts!( @@ -423,7 +423,7 @@ fn union_linked_list_nil_dec() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn union_linked_list_long_dec() { assert_refcounts!( indoc!( @@ -455,7 +455,7 @@ fn union_linked_list_long_dec() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn boxed_str_inc() { assert_refcounts!( indoc!( @@ -475,7 +475,7 @@ fn boxed_str_inc() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn boxed_str_dec() { assert_refcounts!( indoc!( @@ -498,7 +498,7 @@ fn boxed_str_dec() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn non_nullable_unwrapped_alignment_8() { assert_refcounts!( indoc!( @@ -528,7 +528,7 @@ fn non_nullable_unwrapped_alignment_8() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn reset_reuse_alignment_8() { assert_refcounts!( indoc!( diff --git a/crates/compiler/test_gen/src/gen_set.rs b/crates/compiler/test_gen/src/gen_set.rs index 52727405b7..e046899e0f 100644 --- a/crates/compiler/test_gen/src/gen_set.rs +++ b/crates/compiler/test_gen/src/gen_set.rs @@ -1,5 +1,5 @@ #![cfg(all( - any(feature = "gen-llvm"), + feature = "gen-llvm", not(debug_assertions) // https://github.com/roc-lang/roc/issues/3898 ))] @@ -16,7 +16,7 @@ use indoc::indoc; use roc_std::RocList; #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn empty_len() { assert_evals_to!( indoc!( @@ -30,7 +30,7 @@ fn empty_len() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn single_len() { assert_evals_to!( indoc!( @@ -44,7 +44,7 @@ fn single_len() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn single_to_list() { assert_evals_to!( indoc!( @@ -68,7 +68,7 @@ fn single_to_list() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn insert() { assert_evals_to!( indoc!( @@ -86,7 +86,7 @@ fn insert() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn remove() { assert_evals_to!( indoc!( @@ -105,7 +105,7 @@ fn remove() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn union() { assert_evals_to!( indoc!( @@ -126,7 +126,7 @@ fn union() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn difference() { assert_evals_to!( indoc!( @@ -147,7 +147,7 @@ fn difference() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn intersection() { assert_evals_to!( indoc!( @@ -168,7 +168,7 @@ fn intersection() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn walk_sum() { assert_evals_to!( indoc!( @@ -182,7 +182,7 @@ fn walk_sum() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn contains() { assert_evals_to!( indoc!( @@ -206,7 +206,7 @@ fn contains() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn from_list() { assert_evals_to!( indoc!( @@ -238,7 +238,7 @@ fn from_list() { #[test] #[ignore] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn from_list_void() { assert_evals_to!( indoc!( @@ -254,7 +254,7 @@ fn from_list_void() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn to_list_empty() { assert_evals_to!( indoc!( @@ -268,7 +268,7 @@ fn to_list_empty() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn from_list_result() { assert_evals_to!( indoc!( @@ -289,7 +289,7 @@ fn from_list_result() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn resolve_set_eq_issue_4671() { assert_evals_to!( indoc!( diff --git a/crates/compiler/test_gen/src/gen_str.rs b/crates/compiler/test_gen/src/gen_str.rs index 9d28a16536..f5ab49bd0a 100644 --- a/crates/compiler/test_gen/src/gen_str.rs +++ b/crates/compiler/test_gen/src/gen_str.rs @@ -868,7 +868,7 @@ fn str_clone() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn nested_recursive_literal() { assert_evals_to!( indoc!( @@ -1160,7 +1160,7 @@ fn str_trim_large_to_small_unique() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_trim_large_to_large_shared() { assert_evals_to!( indoc!( @@ -1180,7 +1180,7 @@ fn str_trim_large_to_large_shared() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_trim_large_to_small_shared() { assert_evals_to!( indoc!( @@ -1200,7 +1200,7 @@ fn str_trim_large_to_small_shared() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_trim_small_to_small_shared() { assert_evals_to!( indoc!( @@ -1253,7 +1253,7 @@ fn str_trim_start_large_to_small_unique() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_trim_start_large_to_large_shared() { assert_evals_to!( indoc!( @@ -1273,7 +1273,7 @@ fn str_trim_start_large_to_large_shared() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_trim_start_large_to_small_shared() { assert_evals_to!( indoc!( @@ -1293,7 +1293,7 @@ fn str_trim_start_large_to_small_shared() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_trim_start_small_to_small_shared() { assert_evals_to!( indoc!( @@ -1346,7 +1346,7 @@ fn str_trim_end_large_to_small_unique() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_trim_end_large_to_large_shared() { assert_evals_to!( indoc!( @@ -1366,7 +1366,7 @@ fn str_trim_end_large_to_large_shared() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_trim_end_large_to_small_shared() { assert_evals_to!( indoc!( @@ -1386,7 +1386,7 @@ fn str_trim_end_large_to_small_shared() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_trim_end_small_to_small_shared() { assert_evals_to!( indoc!( @@ -1417,7 +1417,7 @@ fn str_to_nat() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_to_i128() { assert_evals_to!( indoc!( @@ -1431,7 +1431,7 @@ fn str_to_i128() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_to_u128() { assert_evals_to!( indoc!( @@ -1473,7 +1473,7 @@ fn str_to_u64() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_to_i32() { assert_evals_to!( indoc!( @@ -1487,7 +1487,7 @@ fn str_to_i32() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_to_u32() { assert_evals_to!( indoc!( @@ -1501,7 +1501,7 @@ fn str_to_u32() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_to_i16() { assert_evals_to!( indoc!( @@ -1515,7 +1515,7 @@ fn str_to_i16() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_to_u16() { assert_evals_to!( indoc!( @@ -1529,7 +1529,7 @@ fn str_to_u16() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_to_i8() { assert_evals_to!( indoc!( @@ -1543,7 +1543,7 @@ fn str_to_i8() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_to_u8() { assert_evals_to!( indoc!( @@ -1557,7 +1557,7 @@ fn str_to_u8() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_to_f64() { assert_evals_to!( indoc!( @@ -1574,7 +1574,7 @@ fn str_to_f64() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_to_f32() { assert_evals_to!( indoc!( @@ -1591,7 +1591,7 @@ fn str_to_f32() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_to_dec() { use roc_std::RocDec; @@ -1910,7 +1910,7 @@ fn str_walk_utf8_with_index() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn str_append_scalar() { assert_evals_to!( indoc!( @@ -1938,7 +1938,7 @@ fn str_walk_scalars() { } #[test] -#[cfg(any(feature = "gen-llvm-wasm"))] +#[cfg(feature = "gen-llvm-wasm")] fn llvm_wasm_str_layout() { assert_evals_to!( indoc!( @@ -1954,7 +1954,7 @@ fn llvm_wasm_str_layout() { } #[test] -#[cfg(any(feature = "gen-llvm-wasm"))] +#[cfg(feature = "gen-llvm-wasm")] fn llvm_wasm_str_layout_small() { // exposed an error in using bitcast instead of zextend assert_evals_to!( diff --git a/crates/compiler/test_gen/src/gen_tags.rs b/crates/compiler/test_gen/src/gen_tags.rs index 0d43fd6c5f..61334af520 100644 --- a/crates/compiler/test_gen/src/gen_tags.rs +++ b/crates/compiler/test_gen/src/gen_tags.rs @@ -1381,7 +1381,7 @@ fn issue_2445() { } #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn issue_2458() { assert_evals_to!( indoc!( diff --git a/crates/compiler/test_gen/src/gen_tuples.rs b/crates/compiler/test_gen/src/gen_tuples.rs index 0ffb2b0e56..5d62885b96 100644 --- a/crates/compiler/test_gen/src/gen_tuples.rs +++ b/crates/compiler/test_gen/src/gen_tuples.rs @@ -319,7 +319,7 @@ fn bool_tuple4_literal() { // Not supported by wasm because of the size of the tuple: // FromWasm32Memory is only implemented for tuples of up to 4 elements #[test] -#[cfg(any(feature = "gen-llvm"))] +#[cfg(feature = "gen-llvm")] fn i64_tuple9_literal() { assert_evals_to!( indoc!( diff --git a/crates/compiler/test_gen/src/wasm_str.rs b/crates/compiler/test_gen/src/wasm_str.rs index b0dc6e53df..8224fc1c44 100644 --- a/crates/compiler/test_gen/src/wasm_str.rs +++ b/crates/compiler/test_gen/src/wasm_str.rs @@ -265,7 +265,7 @@ fn str_concat_big_to_big() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn small_str_literal() { assert_evals_to!( "\"01234567890\"", @@ -275,7 +275,7 @@ fn small_str_literal() { } #[test] -#[cfg(any(feature = "gen-wasm"))] +#[cfg(feature = "gen-wasm")] fn small_str_zeroed_literal() { // Verifies that we zero out unused bytes in the string. // This is important so that string equality tests don't randomly diff --git a/examples/glue/rust-platform/rust-toolchain.toml b/examples/glue/rust-platform/rust-toolchain.toml index 1932d9560f..cc6d7e3f5d 100644 --- a/examples/glue/rust-platform/rust-toolchain.toml +++ b/examples/glue/rust-platform/rust-toolchain.toml @@ -1,5 +1,5 @@ [toolchain] -channel = "1.65.0" +channel = "1.71.1" profile = "default" diff --git a/examples/platform-switching/rust-platform/rust-toolchain.toml b/examples/platform-switching/rust-platform/rust-toolchain.toml index b4dd8635f0..cc6d7e3f5d 100644 --- a/examples/platform-switching/rust-platform/rust-toolchain.toml +++ b/examples/platform-switching/rust-platform/rust-toolchain.toml @@ -1,5 +1,5 @@ [toolchain] -channel = "1.70.0" +channel = "1.71.1" profile = "default" diff --git a/flake.lock b/flake.lock index e1f5519caf..718331d33b 100644 --- a/flake.lock +++ b/flake.lock @@ -43,17 +43,17 @@ }, "nixpkgs": { "locked": { - "lastModified": 1690279121, - "narHash": "sha256-XoPGhV1UJQPue6RiehAu7lQwKss3J1B/K0QtVOMD83A=", + "lastModified": 1693140250, + "narHash": "sha256-URyIDETtu1bbxcSl83xp7irEV04dPEgj7O3LjHcD1Sk=", "owner": "nixos", "repo": "nixpkgs", - "rev": "821c72743ceae44bdd09718d47cab98fd5fd90af", + "rev": "676fe5e01b9a41fa14aaa48d87685677664104b1", "type": "github" }, "original": { "owner": "nixos", "repo": "nixpkgs", - "rev": "821c72743ceae44bdd09718d47cab98fd5fd90af", + "rev": "676fe5e01b9a41fa14aaa48d87685677664104b1", "type": "github" } }, @@ -75,11 +75,11 @@ ] }, "locked": { - "lastModified": 1690252178, - "narHash": "sha256-9oEz822bvbHobfCUjJLDor2BqW3I5tycIauzDlzOALY=", + "lastModified": 1695694299, + "narHash": "sha256-0CucEiOZzOVHwmGDJKNXLj7aDYOqbRtqChp9nbGrh18=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "8d64353ca827002fb8459e44d49116c78d868eba", + "rev": "c89a55d2d91cf55234466934b25deeffa365188a", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index 457857eb34..3575ff2177 100644 --- a/flake.nix +++ b/flake.nix @@ -2,7 +2,7 @@ description = "Roc flake"; inputs = { - nixpkgs.url = "github:nixos/nixpkgs?rev=821c72743ceae44bdd09718d47cab98fd5fd90af"; + nixpkgs.url = "github:nixos/nixpkgs?rev=676fe5e01b9a41fa14aaa48d87685677664104b1"; # rust from nixpkgs has some libc problems, this is patched in the rust-overlay rust-overlay = { diff --git a/rust-toolchain.toml b/rust-toolchain.toml index ebeae83c79..8cd4a6e17d 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -11,9 +11,9 @@ # - update nightly-OLD_DATE in crates/compiler/build/src/link.rs # - Follow instructions in default.nix: `assert pkgs.lib.assertMsg rustVersionsMatch` ... -channel = "1.70.0" # check ^^^ when changing this +channel = "1.71.1" # check ^^^ when changing this # -# channel = "nightly-2023-04-15" # 1.70.0 nightly to be able to use unstable features +# channel = "nightly-2023-05-28" # 1.71.0 nightly to be able to use unstable features profile = "default" components = [ # for usages of rust-analyzer or similar tools inside `nix develop`