mirror of
https://github.com/roc-lang/roc.git
synced 2025-08-04 20:28:02 +00:00
Add new constants to symbol table, attempt to add tests
This commit is contained in:
parent
a0c4bb571f
commit
03e9344a83
2 changed files with 44 additions and 0 deletions
|
@ -3901,3 +3901,43 @@ fn f64_from_parts() {
|
|||
f64
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-dev", feature = "gen-wasm"))]
|
||||
fn nan_f32() {
|
||||
assert_evals_to!(
|
||||
r"Num.nanF32",
|
||||
f32::NAN,
|
||||
f32
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-dev", feature = "gen-wasm"))]
|
||||
fn nan_f64() {
|
||||
assert_evals_to!(
|
||||
r"Num.nanF64",
|
||||
f64::NAN,
|
||||
f64
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-dev", feature = "gen-wasm"))]
|
||||
fn infinity_f32() {
|
||||
assert_evals_to!(
|
||||
r"Num.infinityF32",
|
||||
f32::INFINITY,
|
||||
f32
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-dev", feature = "gen-wasm"))]
|
||||
fn infinity_f64() {
|
||||
assert_evals_to!(
|
||||
r"Num.infinityF64",
|
||||
f64::INFINITY,
|
||||
f64
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue