unnali/rouge — pull request #18 by noprompt (2012-12-03 07:21:03+00:00)
Title: Allow keywords and hashes to be evaluated as functions

These are two of my favorite Clojure features.

```clojure
(def bobby {:fname "Bobby" :lname "Brown"})
(def charlie {:fname "Charlie" :lname "Brown"})
(def people [bobby charlie])

;; Hash as function.
(bobby :fname) ;; "Bobby"

;; Keyword as function.
(:fname charlie) ;; "Charlie"

;; Providing a default value to use if the lookup is nil.
(:mname bobby "Barisford") ;; "Barisford"

;; The opposite works as well.
(bobby :mname "Barisford") ;; "Barisford"

;; And of course this works:
(map :fname people) ;; ("Bobby" "Charlie")
```

It's all tested and ready to go! :)