nandi/rustnimpublic Fork 0
af6e50f646055dc5b291c9e602bc9ee01874f9d6
Commits
Clone
git clone https://git.rickub.com/nandi/rustnim.git
git clone ssh://git@rickub.com/nandi/rustnim.git

Host key fingerprint (ed25519): SHA256:iycHnxEyq0Q7uyVpB7JlznP0G7JrTPXLYRcAU5CSLhc — verify it before your first connect.

Add the differential test runner, and a lowering to measure with it 8ac32af · on af6e50f646055dc5b291c9e602bc9ee01874f9d6 · nandithebull · 15h ago
013-floats.rs · 8 lines · 300 BRust Blame HistoryRaw
1
2
3
4
5
6
7
8
// Rust's Display drops a bare `.0`; Debug keeps it. Nim's `$` does neither
// consistently, so the prelude implements both.
fn main() {
    println!("{} {:?}", 1.0f64, 1.0f64);
    println!("{} {:?}", 1.5f64, 1.5f64);
    println!("{}", 0.1f64 + 0.2f64);
    println!("{} {}", -0.5f64, 100.0f64);
}