[phobos] [D-Programming-Language/phobos] 25abd8: Simplified std.array.join with separator.
GitHub
noreply at github.com
Wed Dec 26 01:58:56 PST 2012
Branch: refs/heads/master
Home: https://github.com/D-Programming-Language/phobos
Commit: 25abd874d11a7a7bcc4a87d34a17e4e6e3c50bfe
https://github.com/D-Programming-Language/phobos/commit/25abd874d11a7a7bcc4a87d34a17e4e6e3c50bfe
Author: Peter Alexander <peter.alexander.au at gmail.com>
Date: 2012-12-25 (Tue, 25 Dec 2012)
Changed paths:
M std/array.d
Log Message:
-----------
Simplified std.array.join with separator.
Previously, std.array.join with a separator would check whether it needed to add the separator on each iteration of the loop. With this change, the check is unnecessary because the first element is appended before the loop, then the loop just adds the separator and next element each iteration.
This improves the code significantly in the case of a non-forward RoR because we don't need to know the length anymore. It's simpler, and will be slightly faster.
Commit: 23ed5019b5fc0cf504ed0f7ce2e86b8736bfc9bd
https://github.com/D-Programming-Language/phobos/commit/23ed5019b5fc0cf504ed0f7ce2e86b8736bfc9bd
Author: Alex Rønne Petersen <alex at alexrp.com>
Date: 2012-12-26 (Wed, 26 Dec 2012)
Changed paths:
M std/array.d
Log Message:
-----------
Merge pull request #1032 from Poita/array-join-improvements
Simplified std.array.join with separator.
Compare: https://github.com/D-Programming-Language/phobos/compare/f780ce4f29c4...23ed5019b5fc
More information about the phobos
mailing list