removal of dead functions and methods

ketmar via Digitalmars-d digitalmars-d at puremagic.com
Wed Dec 24 06:15:31 PST 2014


On Wed, 24 Dec 2014 14:08:23 +0000
Dicebot via Digitalmars-d <digitalmars-d at puremagic.com> wrote:

> On Wednesday, 24 December 2014 at 14:04:56 UTC, ketmar via 
> Digitalmars-d wrote:
> > Hello.
> >
> > i was never thinking about it, but recently i found parts of 
> > source
> > code in my compiled D binary. they comes from code generation
> > functions, which only used in compile time, yet still happily 
> > sits in
> > resulting binary. are there any plans to somehow "fix" that?
> 
> LDC fixes that by using garbage collection of unused symbols by 
> default.

yet we have two other compilers too. i didn't checked what GDC does
with "--gc-sections" cli switch, but i think that it doesn't matter.
and DMD pollutes binaries.

and i think that DMD is most widely-used D compiler nowdays.

btw: i can't check it, but does LDC removing unused static methods too?
i think it should do this, as they aren't very different from free
functions internally.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: not available
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20141224/a4d78592/attachment.sig>


More information about the Digitalmars-d mailing list