ref: 913e7e12f5b204bc53b3761e9cd89a5cd5722c6a
parent: 906384e5b4f4d1dfbf045184717668fe99610d53
author: Ori Bernstein <[email protected]>
date: Tue Jan 21 18:32:24 EST 2014
Shuffle things around so that it works with the chartype commit.
--- a/6/simp.c
+++ b/6/simp.c
@@ -1362,7 +1362,7 @@
case Lint:
/* we can only have up to 4 byte immediates, but they
* can be moved into 64 bit regs */
- if (args[0]->lit.intval < 0xffffffff)
+ if (args[0]->lit.intval < 0xffffffffULL)
r = n;
else
r = simpblob(s, n, &s->blobs, &s->nblobs);
--- a/libstd/dial.myr
+++ b/libstd/dial.myr
@@ -1,4 +1,5 @@
use "alloc.use"
+use "chartype.use"
use "die.use"
use "error.use"
use "sys.use"
--- a/libstd/intparse.myr
+++ b/libstd/intparse.myr
@@ -1,3 +1,4 @@
+use "chartype.use"
use "die.use"
use "fmt.use"
use "hasprefix.use"
@@ -63,21 +64,4 @@
else
-> `Some v
;;
-}
-
-generic charval = {c, base
- var v = -1
-
- if c >= '0' && c <= '9'
- v = (c - '0') castto(@a::(tcint,tcnum,tctest))
- elif c >= 'a' && c <= 'z'
- v = (c - 'a' + 10) castto(@a::(tcint,tcnum,tctest))
- elif c >= 'A' && c <= 'Z'
- v = (c - 'A' + 10) castto(@a::(tcint,tcnum,tctest))
- ;;
-
- if v < 0 || v > (base castto(@a::(tcint,tcnum,tctest)))
- -> -1
- ;;
- -> v
}
--- a/libstd/ipparse.myr
+++ b/libstd/ipparse.myr
@@ -3,6 +3,7 @@
use "option.use"
use "strfind.use"
use "types.use"
+use "chartype.use"
/* FIXME: needed for decls which should be pulled in as hidden */
use "hasprefix.use"