评论者:chrisbetz
实际上,这是造成困扰的代码片段的链接:(链接:[https://github.com/clojure/clojure/blob/master/src/jvm/clojure/lang/AFunction.java](https://github.com/clojure/clojure/blob/master/src/jvm/clojure/lang/AFunction.java) 文本:clojure.lang.AFunction)
`
public abstract class AFunction extends AFn implements IObj, Comparator, Fn, Serializable {
public volatile MethodImplCache __methodImplCache;
`
AFunction 是可序列化的,但 MethodImplCache 不是。我不确定将其标记为 transient 是否足够,因为我没有检查初始化发生在哪里。