Created
June 24, 2016 15:15
-
-
Save Jannis/51ebdd54e10074fd9c574a54dd8421c9 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ;;;; Macro definition | |
| (s/fdef defcommand | |
| :args (s/cat :name ::command-name | |
| :description (s/? ::command-description) | |
| :inputs ::command-inputs | |
| :forms (s/* ::command-form) | |
| :implementation ::command-implementation) | |
| :ret ::s/any) | |
| (defmacro defcommand | |
| [name & forms] | |
| (println "NAME" name) | |
| (println "FORMS" forms)) | |
| ;;;; Testing | |
| boot.user=> (clojure.spec.test/check-var #'workflo.macros.command/defcommand :num-tests 10) | |
| NAME [[] #object[clojure.spec$spec_impl$reify__12782 0x6a079c03 clojure.spec$spec_impl$reify__12782@6a079c03]] | |
| FORMS (()) | |
| NAME () | |
| FORMS (()) | |
| NAME (> :?_-) | |
| FORMS nil | |
| NAME (:Plo 1) | |
| FORMS (() (?.S.-/_WT- 0 0) (:!!8Y)) | |
| NAME (:WP*_w :w8:!2+W) | |
| FORMS ((0.90625 -3 1) () (:F:BR+:-175-:-j)) | |
| NAME [[[!r-.u!_+*y.Yd/-U_. {_F Feature}]] #object[clojure.spec$spec_impl$reify__12782 0x6a079c03 clojure.spec$spec_impl$reify__12782@6a079c03]] | |
| FORMS (() (0 :Y!wJv* # :m+*A-.r5J.T._GT.Q!9/G985) (/) (vHF;h kz) (W7G true) (-2.75 ?6s5I :F05?:4QF:?:!t:d7+9)) | |
| NAME () | |
| FORMS (()) | |
| NAME [[] #object[clojure.spec$spec_impl$reify__12782 0x6a079c03 clojure.spec$spec_impl$reify__12782@6a079c03]] | |
| FORMS ((false 3/2) (t/eC8e* -3.0 :bsW?uY/g+* .-QE :hG9t_ false :_*8WP.H*Yn?1Y/_J!K6dl) () () (:g35*_?O! true) (19 2 0 :V-O15e_6.!!Z.H.EQ+-k2.s4E*ZjSO.w?1.z/tM*I*+19 2.0 ( #uuid "2af6d444-5dcb-40b9-ab85-430175176160") (-5 E :_+-:_3:dx!u8__ 1 -1/2 1.0) ("W]1Kt 3 #uuid "b32e5cab-cb4c-4aef-8c7e-83576a8fbc7a" ) false)) | |
| NAME [[] #object[clojure.spec$spec_impl$reify__12782 0x6a079c03 clojure.spec$spec_impl$reify__12782@6a079c03]] | |
| FORMS ((#uuid "fc71ab12-5302-4837-9e1b-bf4a5369ff0d" -2 #uuid "bd217546-3f77-45fe-8f0d-f2134b1f7727" +_6/o4Gnj.1 -0.3984375) (0 -5 -3 :P_++z?-KW:7+hEb-!8x:f+g :*8V?Qb1*P/n+0+X)) | |
| NAME [[[([h7-0H+hp.V+J-F6Y?z.-/up7-H*c [[] [_aLc6h07 -0.625 26] (GÔ,o)]] {tZOX.H312_4_a!vY.*2/M!N+_Do 10, QS**3*497.-??1*!4z-.ry-8.*!?tf3+3*?6.MQ+2?_5*.!*?--+_8-G!m.NF/F!? 10, n+30.*?lsI8B?-j5.Y8C?+XL.u?9.OT.vA?0.!wB!9.K*.R3*.G/K+ #uuid "acf09738-4fb6-4d8b-a0a0-47b5947bc471", G.yu-2vI5*hj-.S6CW8._-?nEL5.zL._+8h6N.eP54I.THY3c_+9/KCY*mV Q, ?3-.e03-EZk!K4.iW4.T_.C.UN!cz_2_?_.Dgq_?kh.*?mp-h.f?4G9-KK?2o!.C6._e/i.+ .})]] #object[clojure.spec$spec_impl$reify__12782 0x77d080da clojure.spec$spec_impl$reify__12782@77d080da]] | |
| FORMS ((5/8 9 -46 #uuid "8a4911df-e131-4534-bba6-c55e3e4cbc84") (false F.FD?!.v_c0E0D7-!.-*us?9Jly.W5/t-? true true false O_j [) (-2 :v+T.L148e10t.cH??.K9Tv+.MX9_.Y+-h.vrc-U*RY9/aPb? i.d1/!*DU+L!5*! #uuid "5a862413-e982-4f9c-b625-f036dd02f411")) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment