On 08/13/2011 06:45 PM, jaime wrote:
The only reason that I can imagine is this: because we often use higher-order functions, these higher-order functions will accept functions as its parameters, in such a situation, when we want to use a higher-order function but don't want to pass any "real" functions to it, then we can use function like "identity" and "identity" here is just to fill the role of parameter of higher-order function.
That's what I'm using it for. In a case where I have 2 places requiring the same code before and after one step only used in one case. It would be slightly more work, otherwise.
Are there other functions for the same purpose?
I don't see how there could be, for the very same purpose. Though you might want to consider splitting up functions some more, instead.
-- Thorsten Wilms thorwil's design for free software: http://thorwil.wordpress.com/ -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en