About ref used for performance reasons with struct

deadalnix deadalnix at gmail.com
Mon Feb 11 02:55:31 PST 2013


On Monday, 11 February 2013 at 10:21:30 UTC, Paulo Pinto wrote:
> How does this work in the context of modular programming?
>
> Does the compiler generate multiple code for each case, to make 
> the code work regardless of what is decided at the call site?
>
> Or is the code written in a canonical form inside the module, 
> which gets to be rewritten when all modules are linked into the 
> final binary?
>
> By modules I mean the case where you only have a .di file + 
> binary code for the module. For me the right form to distribute 
> libraries.
>

I think it is reasonable to say that this will not work is the 
compiler don't have callee's implementation.


More information about the Digitalmars-d mailing list