I sometimes use join() in this way. join( [""] ~ ["aa","bb","cc"], " @" ) --> " @aa @bb @cc" This doesn't work properly in D2. This is a regression, probably. ------------------------------------------------------ import std.stdio; import std.array; void main() { string[] ary = ["","aa","bb","cc"]; // leaded by _empty_ element writeln(ary.join(" @")); // In 2.067b2, this outputs "aa @bb @cc" or asserts inside of join() assert(ary.join(" @") == " @aa @bb @cc"); // OK in 2.067b1 and olders } ------------------------------------------------------
Commits pushed to master at https://github.com/D-Programming-Language/phobos https://github.com/D-Programming-Language/phobos/commit/43e56d57a51ef6a3240a459d3e6068fc4a9292a5 Fix Issue 14230 - std.array.join misses the first element which is empty string https://github.com/D-Programming-Language/phobos/commit/b43a7b8b6095e19d93d479942c084e6f588adc3d Merge pull request #3027 from sinkuu/fix_14230 Fix Issue 14230 - [REG2.067b2] std.array.join misses the first element which is empty string
Commit pushed to 2.067 at https://github.com/D-Programming-Language/phobos https://github.com/D-Programming-Language/phobos/commit/b4fa59bd736c30c183039044fe48d7477a1cc615 Merge pull request #3027 from sinkuu/fix_14230 Fix Issue 14230 - [REG2.067b2] std.array.join misses the first element which is empty string
Introduced in https://github.com/D-Programming-Language/phobos/pull/2966 Fixed by https://github.com/D-Programming-Language/phobos/pull/3027
Commit pushed to master at https://github.com/D-Programming-Language/phobos https://github.com/D-Programming-Language/phobos/commit/b4fa59bd736c30c183039044fe48d7477a1cc615 Merge pull request #3027 from sinkuu/fix_14230
Commits pushed to stable at https://github.com/D-Programming-Language/phobos https://github.com/D-Programming-Language/phobos/commit/43e56d57a51ef6a3240a459d3e6068fc4a9292a5 Fix Issue 14230 - std.array.join misses the first element which is empty string https://github.com/D-Programming-Language/phobos/commit/b43a7b8b6095e19d93d479942c084e6f588adc3d Merge pull request #3027 from sinkuu/fix_14230
Commits pushed to dmd-cxx at https://github.com/dlang/phobos https://github.com/dlang/phobos/commit/43e56d57a51ef6a3240a459d3e6068fc4a9292a5 Fix Issue 14230 - std.array.join misses the first element which is empty string https://github.com/dlang/phobos/commit/b43a7b8b6095e19d93d479942c084e6f588adc3d Merge pull request #3027 from sinkuu/fix_14230