view tests/mini/typeinfo.d @ 1115:af625ea2d3cf

Call _d_array_bounds when an associative array is indexed with a non-existent key (unless it's being assigned to). Closes #233.
author Frits van Bommel <fvbommel wxs.nl>
date Sat, 14 Mar 2009 01:22:05 +0100
parents 1bb99290e03a
children
line wrap: on
line source

module typeinfo;
extern(C) int printf(char*, ...);

void main()
{
    auto ti = typeid(int);
    char[] str = ti.toString();
    printf("%.*s\n", str.length, str.ptr);
    assert(str == "int");
}