------- Additional Comments From dopheide at fmf dot nl  2005-03-15 18:46 
-------
You are correct. I was wrong.

I thought, because of consistency reasons, that
1) both should link, or
2) both shouldn't link.
(And I choose 1) for the "bug"-report.)

As I now understand it, the "static int const A = 1;" will be seen as an
"integral constant expression". If, OTOH, a reference has to be taken, it is
seen as a "normal int", thus requiring an actual definition. (It is in 9.4.2 of
the standard.)

See also bugs 14404, 13259, 15244, 17673.

(I search the bugs database before filing, but could not find it.)

It stills /looks/ inconsistent though.

-- 


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

Reply via email to