Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Partial implementation of 'flow-let' in user ns

  • Loading branch information...
commit 07f566c33ec2a9c9b5b424622b196a550b2caefa 1 parent 4a81ca3
Stuart Sierra authored

Showing 1 changed file with 12 additions and 1 deletion. Show diff stats Hide diff stats

  1. +12 1 dev/user.clj
13 dev/user.clj
@@ -45,4 +45,15 @@
45 45 ;; "Elapsed time: 19.598 msecs"
46 46 ;; "Elapsed time: 21.219 msecs"
47 47 ;; "Elapsed time: 20.001 msecs"
48   -;; nil
  48 +;; nil
  49 +
  50 +(comment
  51 + (defmacro flow-let [bindings-and-return]
  52 + {:pre [(odd? (count pairs))]}
  53 + (let [bindings (butlast bindings)
  54 + return (last bindings-and-return)
  55 + graph (reduce (fn [graph [output [inputs & body]]]
  56 + (reduce #(dep/depend %1 output %2)
  57 + inputs))
  58 + (dep/graph) bindings)
  59 + todo ])))

0 comments on commit 07f566c

Please sign in to comment.
Something went wrong with that request. Please try again.