view test/bug3.d @ 28:1c80c18f3c82 trunk

[svn r32] * Fixed problems with arrays members of aggregates
author lindquist
date Thu, 04 Oct 2007 12:49:37 +0200
parents
children 253a5fc4033a
line wrap: on
line source

module bug3;

struct S
{
    int[] arr;
    char[5] ch;
}

void main()
{
    S s;
    s.arr = new int[5];
    s.arr[1] = 32;
    assert(s.arr[0] == 0);
    assert(s.arr[1] == 32);
}