------- Additional Comments From jody-atd-030903 at atdesk dot com  2005-02-24 
19:33 -------
I am not on the gcc team, so feel free to take this with some reservation.

According to 5.2.8.5, the top-level cv-qualifier are stripped when calling 
typeid().

According to 3.9.3.[2,5], cv-qualifiers applied to array types apply to the
array elements, not to the array.

Thus, I think the name you see is correct.  In your example, you should be able
to see typeid() doing the right thing (and see that the top-level cv-qualifers
are being stripped) with...

int x[10];
assert(typeid(::v5) == typeid(int[10]));
assert(typeid(::v5) == typeid(x));
assert(strcmp(typeid(::v5).name(), typeid(x).name()) == 0);



-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20123

Reply via email to