clojure-dev

Issues: https://clojure.atlassian.net/browse/CLJ | Guide: https://insideclojure.org/2015/05/01/contributing-clojure/
2019-12-11T19:27:44.381400Z

I was reading clojure.lang.MultiFn and noticed the use of Util#ret1 (e.g here: https://github.com/clojure/clojure/blob/master/src/jvm/clojure/lang/MultiFn.java#L242-L248)

👍 1
2019-12-11T19:28:02.381800Z

is the intent to play with the GC?

2019-12-11T19:31:32.382800Z

it is replicating locals clearing

2019-12-11T19:33:11.384400Z

ah, gotcha, thanks

2019-12-11T19:33:27.384700Z

the clojure compiler will generate jvm bytecode that loads a local on to the stack, then nulls out the local, then does whatever with the value on the stack, which means the local isn't keeping a reference around anymore, but you cannot directly replicate that bytecode as java source code

👍 3