Created
October 20, 2014 21:55
-
-
Save adam-e-trepanier/2383227e043d93c68923 to your computer and use it in GitHub Desktop.
Restructuring with auto resolve
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; In Clojure 1.6 we can now also auto resolve keyword forms in the :keys directive | |
;; I think you lose some context with auto-resolve, but its the shortest code | |
(let [{:keys [name date-of-birth orders | |
::street ::city ::state ::postal-code] | |
:as patient} data] | |
(println name \- date-of-birth) | |
(println street ", " city ", " state " " postal-code) | |
(println orders) | |
(println "------- Full Patient Deatils -----") | |
(println patient)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment