On Thursday, 16 March 2017 at 17:51:41 UTC, Adam D. Ruppe wrote:
On Thursday, 16 March 2017 at 17:40:51 UTC, H. S. Teoh wrote:
Seems like the real cause of bug 17261 is implicit slicing.
Yes, sorry, it took me 10 mins to type it up (I like to double
check the current behavior before posting) but I think we both
see it the same way now.
Guys, seriously this bug has been fixed for quite some time:
https://issues.dlang.org/show_bug.cgi?id=8838
https://issues.dlang.org/show_bug.cgi?id=12625
https://github.com/dlang/dmd/pull/5972
Why don't you use -dip1000???
/home/zombinedev/dlang/dmd-2.073.2/linux/bin64/../../src/phobos/std/stdio.d(3439):
Error: template std.stdio.File.LockingTextWriter.put cannot deduce function
from argument types !()(string), candidates are:
/home/zombinedev/dlang/dmd-2.073.2/linux/bin64/../../src/phobos/std/stdio.d(2643):
std.stdio.File.LockingTextWriter.put(A)(A writeme) if (is(ElementType!A : const(dchar))
&& isInputRange!A && !isInfinite!A)
/home/zombinedev/dlang/dmd-2.073.2/linux/bin64/../../src/phobos/std/stdio.d(2672):
std.stdio.File.LockingTextWriter.put(C)(C c) if (is(C : const(dchar)))
scope_test.d(5): Error: template instance
std.stdio.writeln!string error instantiating
scope_test.d(11): Error: scope variable ans may not be returned
The only issue is that not enough people (except Walter & Andrei)
are interested in pushing -dip1000 as the default. Druntime
already compiles with -dip1000, so Phobos is the next frontier.