This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: const static initializers versionitis
On Aug 22, 2000, Gianni Mariani <gianni@mariani.ws> wrote:
> I want a "static" - so declaring it extern is specifically not
> what I (ideally) would want. i.e. can't have an "extern static"
> declaration.
I see. You'll hopefully have better luck with anonymous namespaces.
AFAICT, there's no way to forward-declare static data items in C++.
namespace {
extern const struct foo bar[];
extern const struct foo tar[];
const struct foo bar[] = { ... };
const struct foo tar[] = { ... };
}
--
Alexandre Oliva Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist *Please* write to mailing lists, not to me