summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/clj/clojure/core.clj6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/clj/clojure/core.clj b/src/clj/clojure/core.clj
index 1285dd2c..9b18b009 100644
--- a/src/clj/clojure/core.clj
+++ b/src/clj/clojure/core.clj
@@ -378,6 +378,12 @@
[#^clojure.lang.IFn f & args]
(. f (applyTo (spread args))))
+(defn vary-meta
+ "Returns an object of the same type and value as obj, with
+ (apply f (meta obj) args) as its metadata."
+ [obj f & args]
+ (with-meta obj (apply f (meta obj) args)))
+
(defn list*
"Creates a new list containing the item prepended to more."
[item & more]