Skip to content

Instantly share code, notes, and snippets.



Created Jul 1, 2015
What would you like to do?
def thwarting laziness?
user=> (defn foo [& fns] (fn [] (->> fns (map #(%)) (filter (comp not nil?)) (first))))
user=> ((foo (fn [] nil) (fn [] "OK") (fn [] (do (print "NONONO") "NO"))))
user=> (def blah (foo (fn [] nil) (fn [] "OK") (fn [] (do (print "NONONO") "NO"))))
user=> (blah)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.