/libs.arc
Unknown | 28 lines | 24 code | 4 blank | 0 comment | 0 complexity | 4b5a014343c3fabe481b8431fcffb50a MD5 | raw file
1(map load '("strings.arc" 2 "code.arc" 3 "html.arc" 4 "srv.arc" 5 "app.arc" 6 "prompt.arc")) 7 8; We define 'require here, rather than in a file in load/ so that things in 9; load/ can use it for load-ordering. 10(unless (and (bound 'required-files*) required-files*) 11 (= required-files* (table))) 12 13(def require (file) 14 " Loads `file' if it has not yet been `require'd. Can be fooled by changing 15 the name ((require \"foo.arc\") as opposed to (require \"./foo.arc\")), but 16 this should not be a problem. 17 See also [[load]]. " 18 (or (required-files* file) 19 (do (set required-files*.file) 20 (load file)))) 21 22(def autoload ((o dirname "load")) 23 " 'require each file in `dirname' ending in \".arc\". 24 See also [[require]] " 25 (each f (dir-exists&dir dirname) 26 (if (endmatch ".arc" f) (require (+ dirname "/" f))))) 27 28(autoload)