New hash
Andrej Mitrovic
andrej.mitrovich at gmail.com
Fri Mar 23 20:21:21 PDT 2012
On 3/24/12, H. S. Teoh <hsteoh at quickfur.ath.cx> wrote:
> On Sat, Mar 24, 2012 at 02:39:35AM +0100, Andrej Mitrovic wrote:
>> I thought I'd open this topic for discussion of issues with the new
>> hash implementation.
> [...]
>
> Another issue:
>
> AA!(string,int[]) aa;
> auto x = aa.get("abc", []);
Yeah, templates are unforgiving sometimes.
How do you nest your hash type? int[int][int] to AA?
I've tried: alias AA!(int, AA!(int, int)) Assoc;
but then I get:
newAA.d(461): Error: safe function 'opIndexAssign' cannot call system
function 'opAssign'
newAA.d(330): Error: template instance
newAA.AA!(int,AA!(int,int)).AssociativeArray.opIndexAssign!(int) error
instantiating
More information about the Digitalmars-d
mailing list