This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-04-07
Channels
- # admin-announcements (4)
- # aws (2)
- # beginners (25)
- # boot (116)
- # braid-chat (4)
- # cider (6)
- # cljsjs (4)
- # cljsrn (17)
- # clojure (196)
- # clojure-austin (23)
- # clojure-belgium (5)
- # clojure-dev (78)
- # clojure-dusseldorf (6)
- # clojure-italy (2)
- # clojure-japan (6)
- # clojure-poland (1)
- # clojure-russia (132)
- # clojure-sdn (1)
- # clojure-uk (26)
- # clojurescript (87)
- # code-reviews (3)
- # core-async (26)
- # cursive (8)
- # datomic (40)
- # devcards (8)
- # emacs (4)
- # funcool (32)
- # hoplon (30)
- # jaunt (34)
- # jobs (1)
- # lein-figwheel (1)
- # leiningen (5)
- # om (14)
- # onyx (8)
- # overtone (31)
- # parinfer (14)
- # proton (8)
- # protorepl (1)
- # re-frame (30)
- # reagent (10)
- # spacemacs (2)
- # untangled (107)
- # yada (3)
@bronsa: so I've been digging on that fn .withMeta
thing you pointed out yesterday, and I'm pretty much convinced that the AFn.withMeta
is dead code.
ObjExpr.compile
already creates .withMeta()
and .meta()
implementations unconditionally both for deftypes and fns. Demo of this behavior above. If the default abstract class implementation were running, then that vary-meta
invocation would have returned a different class type.
ompiled from "test.clj"
public final class test$fn__18 extends clojure.lang.AFunction {
public test$fn__18();
Code:
0: aload_0
1: invokespecial #9 // Method clojure/lang/AFunction."<init>":()V
4: return
public static java.lang.Object invokeStatic();
Code:
0: aconst_null
1: areturn
public java.lang.Object invoke();
Code:
0: invokestatic #14 // Method invokeStatic:()Ljava/lang/Object;
3: areturn
public static {};
Code:
0: return
}
I guess just make supportsMeta
return true in FnExpr
rather than checking for hasMeta
then