Hi folks, I just committed a new contrib lib, an experimental tree walker for Clojure. I'm hoping it will make it easier to write macros that need to do transformations arbitrary code structures.
-Stuart Sierra ------------------------- clojure.contrib.walk/walk ([f form]) Performs a depth-first, post-order traversal of form. Calls f on each sub-form, uses f's return value in place of the original. Recognizes all Clojure data structures except sorted-map-by. Consumes seqs as with doall. ------------------------- clojure.contrib.walk/walk-replace ([smap form]) Recursively transforms form by replacing keys in smap with their values. Like clojure/replace but works on any data structure. ------------------------- clojure.contrib.walk/keywordize-keys ([m]) Recursively transforms all map keys from strings to keywords. ------------------------- clojure.contrib.walk/stringify-keys ([m]) Recursively transforms all map keys from keywords to strings. ------------------------- clojure.contrib.walk/pr-walk ([form]) Demonstrates the behavior of walk by printing each form as it is walked. Returns form. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~----------~----~----~----~------~----~------~--~---
