Associative Arrays in the data segment

Daniel Murphy via Digitalmars-d digitalmars-d at puremagic.com
Fri Apr 10 08:48:10 PDT 2015


"H. S. Teoh via Digitalmars-d"  wrote in message 
news:mailman.1417.1428680037.3111.digitalmars-d at puremagic.com...

> I think this is unacceptable. We're trying to decouple AA's from
> compiler innards, and this is going backwards and adding a huge
> dependency between them again, not to mention being a maintenance
> nightmare because bugs are bound to happen when the two code bases go
> out of sync. It's the very problem we've been trying to fix for years.

That's what tests are for.

> While I am very much in favor of compile-time initialized AA's (been
> wanting that for years now), I think this is not the right approach.  In
> my mind, the correct approach is to factor out the AA implementation
> into a library solution, and use CTFE on that library code to generate
> the compile-time initialized literal.

How many years are you willing to wait for the 'correct approach'?



More information about the Digitalmars-d mailing list