Questions about a constant array reference in the C++ front end

Mark Mitchell mark@codesourcery.com
Tue May 10 01:13:00 GMT 2005


Paul Schlie wrote:

> 
> - ??? no such thing, you can't "dynamically" initialize a "static const",
>   as then it's not a "static const", but rather simply a global "const"
> 
>   (as a "static const" object is logically equivalent to a named/addressable
>    literal, yes?)

No, it's not.

static const int i = f();

-- 
Mark Mitchell
CodeSourcery, LLC
mark@codesourcery.com
(916) 791-8304



More information about the Gcc mailing list