Meikel Brandmeyer committed 220a457

Fixed get-state

* monad/state.clj (get-state): this is actually a monad not a function
of a monad. Hence remove spurious argument.

  • Participants
  • Parent commits e2b2abd

Comments (0)

Files changed (1)

File src/de/kotka/monad/state.clj

 (clojure.core/ns de.kotka.monad.state
-     de.kotka.monad))
+     de.kotka.monad
+     [clojure.contrib.def :only (defvar)]))
 (defn put-value
   "Sets the value but leaves the state intact."
   (return ::type #(vector x %)))
-(defn get-state
-  "Returns the state as the value."
-  [x]
-  (return ::type #(vector % %)))
+  get-state
+  (return ::type #(vector % %))
+  "Returns the state as the value.")
 (defn put-state
   "Sets the state and a nil value."