summaryrefslogtreecommitdiff
path: root/lib/std/units.myr
diff options
context:
space:
mode:
authorOri Bernstein <ori@eigenstate.org>2015-08-26 12:20:58 -0700
committerOri Bernstein <ori@eigenstate.org>2015-08-26 12:20:58 -0700
commit2bc852bda98762d3bc01548bf972e3f1b137fbfb (patch)
tree74831deed3c9057c5fe0cbb8790d220e855bc792 /lib/std/units.myr
parent3de952510eb2a23350d24ed926f19c0cf72a12f2 (diff)
downloadmc-2bc852bda98762d3bc01548bf972e3f1b137fbfb.tar.gz
Move Myrddin libs to lib/ subdirectory.
Diffstat (limited to 'lib/std/units.myr')
-rw-r--r--lib/std/units.myr11
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/std/units.myr b/lib/std/units.myr
new file mode 100644
index 0000000..f1a99e9
--- /dev/null
+++ b/lib/std/units.myr
@@ -0,0 +1,11 @@
+pkg std =
+ /* JEDEC 100B.1 memory sizes */
+ generic KiB : @a::(integral,numeric) = 1024
+ generic MiB : @a::(integral,numeric) = KiB*1024
+ generic GiB : @a::(integral,numeric) = MiB*1024
+ generic TiB : @a::(integral,numeric) = GiB*1024
+ generic PiB : @a::(integral,numeric) = TiB*1024
+ generic EiB : @a::(integral,numeric) = PiB*1024
+ generic ZiB : @a::(integral,numeric) = EiB*1024
+ generic YiB : @a::(integral,numeric) = ZiB*1024
+;;