On 06/27/2012 02:53 PM, Andrei Alexandrescu wrote:
On 6/24/12 9:40 AM, Jonathan M Davis wrote:
On Sunday, June 24, 2012 15:30:15 David Nadlinger wrote:
There is a serious @safe-ty issue with the current
implementation: randomUUID/parseUUID are marked @trusted, but
take an arbitrary range as template parameter, the methods of
which might be @system.

Nice catch. I failed to notice that and should have. @trusted on
templated
functions is generally wrong.

Yah, inferred qualifiers need generally not be specified with templates
unless explicitly meant to restrict code.

Andrei

The issue is this one:

auto fun(alias a)(){ // inferred @system for @safe a
    ... // trusted code
    a();
    ... // trusted code
}

IIRC std.conv.emplace suffers from the same problem.

Reply via email to