On Friday, 15 August 2014 at 08:34:22 UTC, Kenji Hara via
Digitalmars-d wrote:
I implemented partial type deduction in AA keys.
https://github.com/D-Programming-Language/dmd/pull/3615
For example:
auto[auto[$]] aa5 = [[1,2]:1, [3,4]:2];
static assert(is(typeof(aa5) == int[int[2]]));
int[int[][$]] aa15 = [[[1],[2]]:1, [[3],[4]]:2];
static assert(is(typeof(aa15) == int[int[][2]]));
Kenji Hara
Neat. I see as well that you thought of a case that I didn't:
auto[shared const] aa4 = [1:1, 2:2]
I think this partial type inference is a very interesting feature.