DIP 1027--String Interpolation--Final Review Discussion Thread

Jonathan Marler johnnymarler at gmail.com
Fri Jan 31 11:37:44 UTC 2020

On Friday, 31 January 2020 at 02:29:15 UTC, Walter Bright wrote:
> On 1/30/2020 4:39 AM, Seb wrote:
>> Structs are essentially just fancy tuples and look the same 
>> when stored in memory.
> I've wanted to make tuples<=>structs. Here's the big problem - 
> passing them as function parameters.
> It just doesn't work and be compatible with the C ABI.

Could you clarify the problem?  If you have a C function like pow:

extern (C) double pow(double,double);

Is the problem providing a way to call pow with one symbol?


So that's why D hasn't been able to unify structs/tuples? Because 
tuples auto-expand and structs do not?

More information about the Digitalmars-d mailing list