clojure: for loop contents not invoked

前端 未结 1 845
眼角桃花
眼角桃花 2021-01-24 19:55

I\'m trying to build an XML structure using the internal data types from BaseX from Clojure.

(defn basex-elem [token-name dict]
  (let [elem (org.basex.query.ite         


        
相关标签:
1条回答
  • 2021-01-24 20:31

    for is not a loop construct in clojure, rather it's a list comprehension and produces a lazy sequence.

    Use doseq instead when side effects are intended.

    0 讨论(0)
提交回复
热议问题