On Tuesday, 14 May 2019 at 14:36:21 UTC, Q. Schroll wrote:
[snip]
I've filed a bug report [1] some time ago. I'm posting here,
because I want to understand what's going on here.
I read through this post and while I don't know precisely what
the compiler is thinking, it seems for me that your
I have the rather strange question: Why does this work?
struct S
{
int value0;
alias opApply = opApplyImpl!(int delegate(ref int)); //1
int opApplyImpl(DG : int delegate(ref int))(scope DG
callback) //2
{
if (auto result = callback(value0))