Advertisement
Guest User

Untitled

a guest
Aug 7th, 2011
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.22 KB | None | 0 0
  1. (defmacro get-default [type]
  2. `(~(symbol (str type ".")) ~@(repeat (min-items (eval type)) nil)))
  3.  
  4. (defn min-items [type]
  5. (apply min (map #(-> % .getParameterTypes count)
  6. (.getConstructors type))))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement