D-Programming-Language/phobos — pull request #2534 by quickfur (2014-09-19 00:48:02+00:00)
Title: Use new cartesianProduct implementation for 2-argument case as well.

The original implementation will now only be used when one or both the ranges is either non-forward or infinite. The new implementation is also more attribute-friendly (works with pure, nothrow, @nogc, @safe), so this also fixes [issue 13091](https://issues.dlang.org/show_bug.cgi?id=13091).