@safe quiz
Michel Fortin
michel.fortin at michelf.com
Wed Dec 30 15:00:20 PST 2009
On 2009-12-30 15:10:31 -0500, Walter Bright <newshound1 at digitalmars.com> said:
> Michel Fortin wrote:
>> Here, if writeln wasn't safe (and it currently isn't, that should be
>> fixed in Phobos) there is no way this can compile. This is going to be
>> pretty annoying if std.algorithm ever become @safe.
>
> Nobody has gone through Phobos yet and labeled things appropriately.
> This, of course, needs to be done.
I know. But that wasn't really the point of that whole post. The point
is that it's difficult to pass callable arguments to a @safe function
or function template.
Labeling most function templates as @safe in std.algorithm is going to
break code that uses those algorithms. You'll see when you (or someone
else) attempts it, just like I saw when I added @safe to my code.
--
Michel Fortin
michel.fortin at michelf.com
http://michelf.com/
More information about the Digitalmars-d
mailing list