Compile-Time Only Function

Mike via Digitalmars-d digitalmars-d at puremagic.com
Fri Jun 23 04:29:52 PDT 2017


On Friday, 23 June 2017 at 11:24:14 UTC, Moinak Bhattacharyya 
wrote:

> My mistake, it's typeinfo that's being included now. So is 
> memcpy. I don't know why, as they are never used at runtime. 
> How can I avoid this?

Unless you're using GDC with this 
(https://github.com/D-Programming-GDC/GDC/pull/456), TypeInfo is 
always going to be included.

The only way to get a build is write TypeInfo stubs like this 
(https://github.com/JinShil/minimal_druntime_experiment/blob/master/source/d/runtime/object.d#L51)

If you're trying to use D without the runtime, you're going to 
have to provide certain implementations depending on which 
features of D you are using.

Mike



More information about the Digitalmars-d mailing list