void bug4072(T)(T x) if (is(typeof(bug4072(x)))) {} static assert(!is(typeof(bug4072(7)))); ----- PATCH: template.c line 1421. ----------------------------------- Objects dedargs; + static int nest = 0; + if (++nest > 300) + { + global.gag = 0; // ensure error message gets printed + error("recursive expansion"); + if (sc->tinst) sc->tinst->printInstantiationTrace(); + fatal(); + } m = td->deduceFunctionTemplateMatch(loc, targsi, ethis, fargs, &dedargs); + --nest; //printf("deduceFunctionTemplateMatch = %d\n", m); if (!m) // if no match continue;
changeset 432
Fixed DMD2.043.