checkpoint

This commit is contained in:
Folkert 2023-09-13 17:23:13 +02:00
parent 3c8dbce72e
commit 5e4f43e1d8
No known key found for this signature in database
GPG key ID: 1F17F6FFD112B97C
12 changed files with 296 additions and 109 deletions

View file

@ -3970,11 +3970,28 @@ fn mul_checked_dec() {
assert_evals_to!(
indoc!(
r#"
Num.mulChecked 5.0dec 2.0dec == Ok 10.0dec
Num.mulChecked 5.0dec 2.0dec
"#
),
true,
bool
RocResult::ok(RocDec::from_str("10.0").unwrap()),
RocResult<RocDec, ()>
);
}
#[test]
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm", feature = "gen-dev"))]
fn mul_checked_u128() {
assert_evals_to!(
indoc!(
r#"
x : Result U128 [ Overflow ]
x = Num.mulChecked 5u128 2u128
x
"#
),
RocResult::ok(5u128 * 2u128),
RocResult<u128, ()>
);
}

View file

@ -2061,7 +2061,7 @@ fn non_unary_union_with_lambda_set_with_imported_toplevels_issue_4733() {
_ -> (\a -> a)
main = ((fn "*") 3) * ((fn "+") 5)
main = ((fn "*") 3i64) * ((fn "+") 5)
"#
),
90,

View file

@ -216,7 +216,7 @@ pub fn helper(
roc_bitcode::host_tempfile().expect("failed to write host builtins object to tempfile");
// TODO make this an environment variable
if false {
if true {
let file_path = std::env::temp_dir().join("app.o");
println!("gen-test object file written to {}", file_path.display());
std::fs::copy(&app_o_file, file_path).unwrap();