Mark Engelberg <[email protected]> writes: > str uses a string builder behind the scenes, so it's efficient this > way.
If the `str' implementation didn't take the input sequence to be lazy, it could figure out how long the resulting string needed to be, and construct the StringBuilder using the single-integer constructor, ensuring that no reallocation and copying occurs. Some temporary allocation would still be necessary to hold the Object-to-String projection, as `str' calls Object#toString() on each argument, rather than assuming the arguments are already of type String. -- Steven E. Harris -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to [email protected] Note that posts from new members are moderated - please be patient with your first post. 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
