summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOri Bernstein <ori@eigenstate.org>2018-01-14 15:08:43 -0800
committerOri Bernstein <ori@eigenstate.org>2018-01-14 15:08:43 -0800
commit9d5831fb236f42fe126160c339a70452ef0fa460 (patch)
tree4d59bae15bf61f7c71096039ce97474b828317ca
parent58fc61a9b04d57ccafa3b1316fbea2faccf5fbbd (diff)
downloadmc-9d5831fb236f42fe126160c339a70452ef0fa460.tar.gz
Fix build on 9front.
-rw-r--r--lib/std/syswrap+plan9.myr36
1 files changed, 18 insertions, 18 deletions
diff --git a/lib/std/syswrap+plan9.myr b/lib/std/syswrap+plan9.myr
index 9f0ccc9..474c5cd 100644
--- a/lib/std/syswrap+plan9.myr
+++ b/lib/std/syswrap+plan9.myr
@@ -261,7 +261,7 @@ const statsz = {buf
}
*/
-generic check = {e : @a::(integral, numeric) -> result(@b, errno)
+generic check = {e : @a -> result(@b, errno) :: integral, numeric @a
if e < 0
-> `Err lasterr()
else
@@ -270,25 +270,25 @@ generic check = {e : @a::(integral, numeric) -> result(@b, errno)
}
/* duplicated code to break dependency cycle */
-generic _getle16 = {buf -> @a::(numeric,integral)
- -> ((buf[0] : @a::(numeric,integral)) << 0) | \
- ((buf[1] : @a::(numeric,integral)) << 8)
+generic _getle16 = {buf -> @a :: numeric,integral @a
+ -> ((buf[0] : @a) << 0) | \
+ ((buf[1] : @a) << 8)
}
-generic _getle32 = {buf -> @a::(numeric,integral)
- -> ((buf[0] : @a::(numeric,integral)) << 0) | \
- ((buf[1] : @a::(numeric,integral)) << 8) | \
- ((buf[2] : @a::(numeric,integral)) << 16) | \
- ((buf[3] : @a::(numeric,integral)) << 24)
+generic _getle32 = {buf -> @a :: numeric,integral @a
+ -> ((buf[0] : @a) << 0) | \
+ ((buf[1] : @a) << 8) | \
+ ((buf[2] : @a) << 16) | \
+ ((buf[3] : @a) << 24)
}
-generic _getle64 = {buf -> @a::(numeric,integral)
- -> ((buf[0] : @a::(numeric,integral)) << 0) | \
- ((buf[1] : @a::(numeric,integral)) << 8) | \
- ((buf[2] : @a::(numeric,integral)) << 16) | \
- ((buf[3] : @a::(numeric,integral)) << 24) | \
- ((buf[4] : @a::(numeric,integral)) << 32) | \
- ((buf[5] : @a::(numeric,integral)) << 40) | \
- ((buf[6] : @a::(numeric,integral)) << 48) | \
- ((buf[7] : @a::(numeric,integral)) << 56)
+generic _getle64 = {buf -> @a :: numeric,integral @a
+ -> ((buf[0] : @a) << 0) | \
+ ((buf[1] : @a) << 8) | \
+ ((buf[2] : @a) << 16) | \
+ ((buf[3] : @a) << 24) | \
+ ((buf[4] : @a) << 32) | \
+ ((buf[5] : @a) << 40) | \
+ ((buf[6] : @a) << 48) | \
+ ((buf[7] : @a) << 56)
}