[Issue 8882] map, filter, iota and zip in pure (and nothrow) functions

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Jan 14 13:22:20 PST 2014


https://d.puremagic.com/issues/show_bug.cgi?id=8882



--- Comment #3 from bearophile_hugs at eml.cc 2014-01-14 13:22:18 PST ---
(In reply to comment #2)

> zip can throw because of StoppingPolicy.requireSameLength, and iota(x,y,z)
> throws when z can be 0. iota(x) and iota(x,y) are nothrow.

even iota(x,y) is not nothrow for floating point arguments:


import std.range: iota;
void main() nothrow {
    iota(1.0, 2.0);
}

test.d(3): Error: 'std.range.iota!(double, double).iota' is not nothrow
test.d(2): Error: function 'D main' is nothrow yet may throw

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list