[Issue 6646] [SafeD] array.reserve is not @safe/trusted

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Aug 5 14:13:06 PDT 2013


http://d.puremagic.com/issues/show_bug.cgi?id=6646



--- Comment #8 from Dmitry Olshansky <dmitry.olsh at gmail.com> 2013-08-05 14:13:05 PDT ---
(In reply to comment #7)
> This can be fixed, since reserve is a template and not a compiler-builtin.
> 
> Unfortunately, we need to manually propagate the @safe/@nothrow to the high
> level reserve call. something like:
> 
> @safe @nothrow reserve(T)(T[] t) if(isPostblitSafe!T && isPostblitNothrow!T)
> 
> etc.
> 
> Ugly...

Shouldn't auto-inference help + local @trusted/nothrow lambdas to encapsulate
dangerous code?

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


More information about the Digitalmars-d-bugs mailing list