On Friday, 20 September 2013 at 16:50:50 UTC, Adam D. Ruppe wrote:
On Friday, 20 September 2013 at 16:44:30 UTC, Temtaime wrote:
Why? I have a large project.
If i replace main with "void main() {}" the size is still 26
MB in debug.
Could be due to things like static module constructors or
typeinfos. There *are* problems with things getting intertwined
and not being considered dead by the linker, but it does try.
The proof of it is hello world being 150 KB instead of the 6 MB
or so it would be if it carried all of the dead code from
phobos too.
You are confusing linking static library and eliminating unused
code from executable binary itself.