cs: rewrite division-by-zero error message

This commit is contained in:
Matthew Flatt 2019-05-22 08:51:06 -06:00
parent 7a6d567daf
commit ba0934521e

View File

@ -63,6 +63,9 @@
"~a: undefined;\n cannot reference an identifier before its definition"
"\n alert: compiler pass failed to add more specific guard!")
irritants)]
[(and (equal? str "undefined for ~s")
(equal? irritants '(0)))
(values "division by zero" null)]
[else
(let ([str (string-copy str)]
[len (string-length str)])