I'm building a graph editor with Piccolo2D and want to implement Loom's Graph protocol. However I run into problem
Unable to resolve symbol: out-edges in this context What really confusing is that I can use successors in has-edge.
(extend-type PCanvas Graph (nodes [g] (->children (->node-layer g))) (edges [g] (->children (->edge-layer g))) (has-node? [g node] (some #{node} (nodes g))) (has-edge? [g n1 n2] (some #{n2} (successors g n1))) (successors ([g] (partial successors g)) ([g node] (remove (partial = node) (distinct (flatten (apply concat (map ->nodes (out-edges g node)))))))) (out-degree [g node] (count (out-edges g node))) (out-edges [g node] (->edges node))) So in what condition protocol methods can call others?
Edit: Full error message: http://pastebin.com/NDWEZZ7y