spit

pathname content


Summary

Read the entirety of PATHNAME and return it as a string if possible, otherwise return #nil.

Bytecode

Probably only interesting to you if you want to understand more about the Nujel VM or care very much about performance.

(    0 ($get/val 'file/open-output*))
(    2 ($get/val 'pathname))
(    4 ($push/val :replace))
(    6 ($apply 2))
(    8 ($det/val 'fh))
(   10 ($drop))
(   11 ($get/val 'fh))
(   13 ($jf* 7))
(   16 ($push/nil))
(   17 ($jmp* 5))
(   20 ($push/false))
(   21 ($ret))
(   22 ($drop))
(   23 ($push/val 'anonymous))
(   25 ($push/val ()))
(   27 ($push/val #@()))
(   29 ($push/val #{##(file/close* fh)
0E000E0104010D1C0101
}))
(   31 ($fn/dynamic))
(   32 ($try 19))
(   33 ($nop))
(   34 ($closure/push))
(   35 ($get/val 'file/write*))
(   37 ($get/val 'fh))
(   39 ($get/val 'content))
(   41 ($apply 2))
(   43 ($drop))
(   44 ($get/val 'file/close*))
(   46 ($get/val 'fh))
(   48 ($apply 1))
(   50 ($closure/pop))
(   51 ($drop))
(   52 ($push/true))
(   53 ($ret))
(   54 ($ret))