add -allinst compiler switch

Iain Buclaw ibuclaw at ubuntu.com
Fri Oct 18 04:47:11 PDT 2013


On 18 October 2013 08:17, Walter Bright <newshound2 at digitalmars.com> wrote:
> Explained here:
>
> http://d.puremagic.com/issues/show_bug.cgi?id=11284
>
> It's a bit complicated, and important.
>
> BTW, I hate the name of the switch, but haven't thought of anything better.

GDC has -femit-templates which emits all templates as private, then
the linker then removes unreferenced templates.  This however is
different from the behavior in 2.063, in that it generates code for
*no really, all* instantiated templates.  This is because of front-end
template bugs when doing separate compilation (especially in
large/complex projects - what you call 'build system irregularities').
 Not sure of what you mean when you say this is the behaviour in
2.063, as if 2.063 *did* emit code for all instantiated templates, I'd
have no need to put in -femit-templates (which emits more code).

-- 
Iain Buclaw

*(p < e ? p++ : p) = (c & 0x0f) + '0';


More information about the Digitalmars-d mailing list