Skip to content

Commit

Permalink
Merge pull request #3046 from John-Colvin/patch-13
Browse files Browse the repository at this point in the history
make 0-arg writeln @trusted: Fix Issue 13681 take 2
  • Loading branch information
JakobOvrum committed Mar 10, 2015
2 parents f22559f + e601077 commit 38453e8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions std/stdio.d
Expand Up @@ -2903,7 +2903,7 @@ void writeln(T...)(T args)
{
import std.exception : enforce;

enforce(fputc('\n', .stdout._p.handle) == '\n');
enforce(fputc('\n', .trustedStdout._p.handle) == '\n');
}
else static if (T.length == 1 &&
is(typeof(args[0]) : const(char)[]) &&
Expand Down Expand Up @@ -2933,7 +2933,7 @@ void writeln(T...)(T args)
}
}

unittest
@safe unittest
{
// Just make sure the call compiles
if (false) writeln();
Expand Down

0 comments on commit 38453e8

Please sign in to comment.