Confusing diagnostic for initializing array with array

Testcase:
int test() {
int a[10];
int b[10] = a;
}

gives the following error:
error: incompatible type initializing 'int [10]', expected 'int [10]'

which is completely confusing. This code obviously isn't legal, but
reason has nothing to do with the type of the initializer.

Not sure what the best wording for this error is, though.

-Eli

Testcase:
int test() {
int a[10];
int b[10] = a;
}

gives the following error:
error: incompatible type initializing 'int [10]', expected 'int [10]'

which is completely confusing. This code obviously isn't legal, but
reason has nothing to do with the type of the initializer.

Not sure what the best wording for this error is, though.

This is what the EDG compiler says...
"ComeauTest.c", line 3: error: initialization with "{...}" expected for aggregate
           object
   int b[10] = a;
               ^
Which looks good to me.

snaroff

Eli Friedman wrote:-

Testcase:
int test() {
int a[10];
int b[10] = a;
}

gives the following error:
error: incompatible type initializing 'int [10]', expected 'int [10]'

which is completely confusing.

I don't see how that message can make sense in any context. I'd
expect it to be complaining about initializing x with y.

Neil.