Re: clojure.spec

2016-05-23 Thread Andrey Grin
could be flowing into the > same location by leveraging a multimethod that conditionally provides the > spec to use. > > On Monday, May 23, 2016 at 3:09:46 PM UTC-5, Andrey Grin wrote: >> >> Thanks, Alex. I've taken random example from plumatic.schema wiki to >> quic

Re: clojure.spec

2016-05-23 Thread Andrey Grin
-1)) > > (gen/sample (spec/gen ::tree) 5) > => (((-1 0) 0) 0 1 (0 1) (1 -3)) > > > On Monday, May 23, 2016 at 11:16:44 AM UTC-5, Alex Miller wrote: >> >> Yes, you can create recursive definitions by registering a spec that >> refers to itself via registered

Re: clojure.spec

2016-05-23 Thread Andrey Grin
Is it planned to support recursive definitions? Example from.plumatic schema: (def BinaryTree (maybe ;; any empty binary tree is represented by nil {:value long :left (recursive #'BinaryTree) :right (recursive #'BinaryTree)})) -- You received this message because you are subs