ref: 2da75521162ef1b19fb047c13c77c5dd33910671
parent: e363cc6bdebc37d56a27cd4fc3d9b03db4c2d6d6
author: Ori Bernstein <ori@eigenstate.org>
date: Thu Aug 31 21:30:00 EDT 2017
Revert some intparse stupidity.
--- a/lib/std/intparse.myr
+++ b/lib/std/intparse.myr
@@ -48,14 +48,11 @@
}
generic doparse = {s, isneg, base -> option(@a::(integral,numeric))
- var c, v, i
+ var v
var cv : int32
v = 0
- i = 0
- while true
- c = std.decode(s[i:])
- i += std.charlen(c)
+ for c : std.bychar(s)
if c == '_'
continue
;;