Skip to content

Instantly share code, notes, and snippets.

@tomjack
Created June 18, 2012 06:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tomjack/2225f2e6152d9a052cb1 to your computer and use it in GitHub Desktop.
Save tomjack/2225f2e6152d9a052cb1 to your computer and use it in GitHub Desktop.
(defn pr-with-opts
"Prints a sequence of objects using string-print, observing all
the options given in opts"
[objs opts]
(let [first-obj (first objs)]
(doseq [obj objs]
(when-not (identical? obj first-obj)
(string-print " "))
(doseq [string (pr-seq obj opts)]
(string-print string)))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment