Mercurial > rlm
comparison src/rlm/function_utils.clj @ 9:1065e7d615a4 tip
deactivate some cruft.
author | Robert McIntyre <rlm@mit.edu> |
---|---|
date | Mon, 08 Jul 2013 12:51:12 -0400 |
parents | b8bbb0dbda7b |
children |
comparison
equal
deleted
inserted
replaced
8:7240d7a5f959 | 9:1065e7d615a4 |
---|---|
81 functions (if (string? (first functions)) (rest functions) functions) | 81 functions (if (string? (first functions)) (rest functions) functions) |
82 arglists (:arglists (meta (resolve (eval `(quote ~(first functions)))))) | 82 arglists (:arglists (meta (resolve (eval `(quote ~(first functions)))))) |
83 name (with-meta name | 83 name (with-meta name |
84 (assoc (meta name) :arglists `(quote ~arglists) | 84 (assoc (meta name) :arglists `(quote ~arglists) |
85 :doc doc-string))] | 85 :doc doc-string))] |
86 `(def ~name (mix ~@functions)))) | 86 `(def ~name (race ~@functions)))) |
87 | 87 |
88 (defn runonce | 88 (defn runonce |
89 "Decorator. returns a function which will run only once. Inspired | 89 "Decorator. returns a function which will run only once. Inspired |
90 by Halloway's version from lancet." | 90 by Halloway's version from lancet." |
91 {:author "Robert McIntyre"} | 91 {:author "Robert McIntyre"} |