Thread overview
[Issue 13091] nothrow std.algorithm.cartesianProduct
July 10, 2014
https://issues.dlang.org/show_bug.cgi?id=13091

hsteoh@quickfur.ath.cx changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |hsteoh@quickfur.ath.cx

--
September 19, 2014
https://issues.dlang.org/show_bug.cgi?id=13091

hsteoh@quickfur.ath.cx changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |pull

--- Comment #1 from hsteoh@quickfur.ath.cx ---
https://github.com/D-Programming-Language/phobos/pull/2534

--
September 19, 2014
https://issues.dlang.org/show_bug.cgi?id=13091

github-bugzilla@puremagic.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--
September 19, 2014
https://issues.dlang.org/show_bug.cgi?id=13091

--- Comment #2 from github-bugzilla@puremagic.com ---
Commits pushed to master at https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/556ef61ef8ede92f06b05e233cf7521f5042a18c 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://github.com/D-Programming-Language/phobos/commit/2bd311c0edf3ecb4d8faa988a3ce2f468479d06f Merge pull request #2534 from quickfur/issue13091

Use new cartesianProduct implementation for 2-argument case as well.

--
September 19, 2014
https://issues.dlang.org/show_bug.cgi?id=13091

--- Comment #3 from bearophile_hugs@eml.cc ---
Thank you.

Do you know the cause of this problem?

void main() @safe {
    import std.algorithm: cartesianProduct;
    import std.array: array;
    const r = cartesianProduct([1], [1]).array;
}



test.d(4,41): Error: safe function 'D main' cannot call system function
'std.array.array!(Result).array'

--