diff options
| author | Josh Wolfe <thejoshwolfe@gmail.com> | 2015-12-15 14:54:16 -0700 |
|---|---|---|
| committer | Josh Wolfe <thejoshwolfe@gmail.com> | 2015-12-15 14:54:16 -0700 |
| commit | 8a570c458bcf62bc3d882f8d253f75ec6d3fd719 (patch) | |
| tree | 2689c80e82a1a0a197af405a51fcd8f9c35296fb /test/run_tests.cpp | |
| parent | 43099932d55c7fa6279cba61eeba91c89a9cb1a0 (diff) | |
| download | zig-8a570c458bcf62bc3d882f8d253f75ec6d3fd719.tar.gz zig-8a570c458bcf62bc3d882f8d253f75ec6d3fd719.zip | |
base 10 decimals work now. closes #15
Diffstat (limited to 'test/run_tests.cpp')
| -rw-r--r-- | test/run_tests.cpp | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/test/run_tests.cpp b/test/run_tests.cpp index 0ca3d77aca..f6d4274bda 100644 --- a/test/run_tests.cpp +++ b/test/run_tests.cpp @@ -474,6 +474,20 @@ export fn main(argc : isize, argv : &&u8, env : &&u8) -> i32 { 0.000000000000000000000000000000000000000000000000000000000e0 as f64); printf(c"0.0e000000000000000000000000000000000000000000000000000000000: %a\n", 0.0e000000000000000000000000000000000000000000000000000000000 as f64); + printf(c"1.0: %a\n", + 1.0 as f64); + printf(c"10.0: %a\n", + 10.0 as f64); + printf(c"10.5: %a\n", + 10.5 as f64); + printf(c"10.5e5: %a\n", + 10.5e5 as f64); + printf(c"10.5e+5: %a\n", + 10.5e+5 as f64); + printf(c"50.0e-2: %a\n", + 50.0e-2 as f64); + printf(c"50e-2: %a\n", + 50e-2 as f64); printf(c"\n"); @@ -524,6 +538,13 @@ export fn main(argc : isize, argv : &&u8, env : &&u8) -> i32 { 000000000000000000000000000000000000000000000000000000000.0e0: 0x0p+0 0.000000000000000000000000000000000000000000000000000000000e0: 0x0p+0 0.0e000000000000000000000000000000000000000000000000000000000: 0x0p+0 +1.0: 0x1p+0 +10.0: 0x1.4p+3 +10.5: 0x1.5p+3 +10.5e5: 0x1.0059p+20 +10.5e+5: 0x1.0059p+20 +50.0e-2: 0x1p-1 +50e-2: 0x1p-1 0x1.0: 0x1p+0 0x10.0: 0x1p+4 |
