Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/clojure/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Clojure 包含conj的接口?_Clojure_Deftype - Fatal编程技术网

Clojure 包含conj的接口?

Clojure 包含conj的接口?,clojure,deftype,Clojure,Deftype,作为练习,我正在开发一个类似于Vector的数据结构。我已经实现了IPersistentVector扩展的所有接口,但是我没有找到定义“conj”的接口。那是哪个接口? 谢谢 clojure.lang.IPersistentCollection/cons。它最初被命名为cons,尽管它的Clojure函数现在被称为conj另一个例子是rest,它在接口端是c.l.ISeq/more。

作为练习,我正在开发一个类似于Vector的数据结构。我已经实现了IPersistentVector扩展的所有接口,但是我没有找到定义“conj”的接口。那是哪个接口?
谢谢

clojure.lang.IPersistentCollection/cons
。它最初被命名为
cons
,尽管它的Clojure函数现在被称为
conj

另一个例子是
rest
,它在接口端是
c.l.ISeq/more