www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - transposed problem

reply "bearophile" <bearophileHUGS lycos.com> writes:
Is this another bug in std.range.transposed?


void main() {
     import std.stdio, std.algorithm, std.range;
     auto M = [[[1, 2]], [[3, 4]]];
     M.filter!(r => r.dup.transposed.walkLength).writeln;
     M.filter!(r => r.transposed.walkLength).writeln;
}


Output with the latest dmd:

[[[1, 2]], [[3, 4]]]
[[[]], [[]]]


Bye,
bearophile
Jul 04 2014
parent "bearophile" <bearophileHUGS lycos.com> writes:
https://issues.dlang.org/show_bug.cgi?id=13041

Bye,
bearophile
Jul 04 2014