summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRich Hickey <richhickey@gmail.com>2010-06-23 08:52:52 -0400
committerRich Hickey <richhickey@gmail.com>2010-06-23 08:52:52 -0400
commita08eac88766fa5eca96d7daf66addc00b70fd1bc (patch)
tree91c2b93a4ea48d4e3f7c27f741aee6bfba3b73de
parent42df6a0ad721a798411e9a701d51a42f6686777f (diff)
disable direct binding (and internal reduce with it, for now)
-rw-r--r--src/clj/clojure/core.clj2
-rw-r--r--src/jvm/clojure/lang/Compiler.java20
2 files changed, 10 insertions, 12 deletions
diff --git a/src/clj/clojure/core.clj b/src/clj/clojure/core.clj
index 2a2563f5..5ad60614 100644
--- a/src/clj/clojure/core.clj
+++ b/src/clj/clojure/core.clj
@@ -5321,7 +5321,7 @@
(load "gvec")
;; redefine reduce with internal-reduce
-(defn reduce
+#_(defn reduce
"f should be a function of 2 arguments. If val is not supplied,
returns the result of applying f to the first 2 items in coll, then
applying f to that result and the 3rd item, etc. If coll contains no
diff --git a/src/jvm/clojure/lang/Compiler.java b/src/jvm/clojure/lang/Compiler.java
index 3aae49f8..f5684f1b 100644
--- a/src/jvm/clojure/lang/Compiler.java
+++ b/src/jvm/clojure/lang/Compiler.java
@@ -2878,17 +2878,15 @@ static class InvokeExpr implements Expr{
this.onMethod = (java.lang.reflect.Method) methods.get(0);
}
}
- else if(pvar == null && VAR_CALLSITES.isBound()
- && fvar.ns.name.name.startsWith("clojure")
- && !RT.booleanCast(RT.get(RT.meta(fvar),dynamicKey))
-// && !fvar.sym.name.equals("report")
-// && fvar.isBound() && fvar.get() instanceof IFn
- )
- {
- //todo - more specific criteria for binding these
- this.isDirect = true;
- this.siteIndex = registerVarCallsite(((VarExpr) fexpr).var);
- }
+// else if(pvar == null && VAR_CALLSITES.isBound()
+// && fvar.ns.name.name.startsWith("clojure")
+// && !RT.booleanCast(RT.get(RT.meta(fvar),dynamicKey))
+// )
+// {
+// //todo - more specific criteria for binding these
+// this.isDirect = true;
+// this.siteIndex = registerVarCallsite(((VarExpr) fexpr).var);
+// }
}
this.tag = tag != null ? tag : (fexpr instanceof VarExpr ? ((VarExpr) fexpr).tag : null);
}