summaryrefslogtreecommitdiff
path: root/libstd/mkpath.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 /libstd/mkpath.myr
parent3de952510eb2a23350d24ed926f19c0cf72a12f2 (diff)
downloadmc-2bc852bda98762d3bc01548bf972e3f1b137fbfb.tar.gz
Move Myrddin libs to lib/ subdirectory.
Diffstat (limited to 'libstd/mkpath.myr')
-rw-r--r--libstd/mkpath.myr22
1 files changed, 0 insertions, 22 deletions
diff --git a/libstd/mkpath.myr b/libstd/mkpath.myr
deleted file mode 100644
index b7e8e24..0000000
--- a/libstd/mkpath.myr
+++ /dev/null
@@ -1,22 +0,0 @@
-use "syswrap.use"
-use "errno.use"
-
-pkg std =
- const mkpath : (p : byte[:] -> bool)
-;;
-
-const mkpath = {p
- var st
- var i
-
- for i = 0; i < p.len; i++
- if p[i] == '/' castto(byte) && i != 0
- st = mkdir(p[:i], 0o777)
- if st != 0 && (st castto(errno)) != Eexist
- -> false
- ;;
- ;;
- ;;
-
- -> true
-}