Article View: gnu.g++.bug
Article #822Shadowing a static data member
From: Hadar Shem-Tov
Date: Wed, 19 Aug 1992 04:46
Date: Wed, 19 Aug 1992 04:46
17 lines
1120 bytes
1120 bytes
I'm not sure if this posting belongs here but I encountered a somewhat strange behavior when I defined a static data member in a derived class that hides another static member of the base class. Basically, the compiler doesn't complain but I keep getting the base class member instead of the desired one and as far as I can see there is no way to access the data in the derived class. Obviously I can (and probably should) redesign my code but I'd still like to know if this is a bug? If not I'd be happy if someone could explain what's going on. ------------------------------------------------------------------------------- Hadar Shemtov Dept. of Linguistics Stanford University
Technical Details
Message-ID:
<1992Aug19.044651.15189@Csli.Stanford.EDU>Path:
arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!csli.stanford.edu!hadarShow Full Headers
Complete Article Headers
Newsgroups: gnu.g++.bug Path: arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!csli.stanford.edu!hadar From: hadar@csli.stanford.edu (Hadar Shem-Tov) Subject: Shadowing a static data member Message-ID: <1992Aug19.044651.15189@Csli.Stanford.EDU> Sender: gnulists@ai.mit.edu Organization: Stanford University CSLI Distribution: gnu Date: Wed, 19 Aug 1992 04:46:51 GMT Approved: bug-g++@prep.ai.mit.edu Lines: 18