shithub: mc

Download patch

ref: 10009f394344f655190934e9c5d654b9bce37032
parent: af128ae8ef5c2d4627ab90e02efe15eca7b8cdb5
author: Ori Bernstein <ori@markovcorp.com>
date: Mon Feb 20 07:30:58 EST 2017

Don't divide by zero.

	It can trap.

--- a/lib/std/test/fltbits.myr
+++ b/lib/std/test/fltbits.myr
@@ -1,5 +1,5 @@
 use std
 
 const main = {
-	std.assert(std.isnan(0./0.), "isnan(0/0) false\n")
+	std.assert(std.isnan(std.flt64nan()), "isnan(nan) false\n")
 }