A little of Partial Compilation

bearophile bearophileHUGS at lycos.com
Tue Aug 19 09:55:04 PDT 2008


Jarrett Billingsley:
> Yes, it means you have to do it manually, but still, it's nice to be able
> to offer an optimized version of a function for certain values for parameters.

Making this "conversion" automatic can be useful because as time passes the D compiler may gain more capabilities to run things at compile time (like I think trigonometric functions, recently, in D 2.x), this means that more values can become run time constants (even ones that the programmer doesn't know can be run time constants), this is an opportunity to optimize some functions more like I have said.

Bye,
bearophile



More information about the Digitalmars-d mailing list