public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
* RE: nested namespace and enum
@ 2003-07-14 17:47 Pavoori, Kiran
  2003-07-15  3:39 ` Daniel Jacobowitz
  0 siblings, 1 reply; 2+ messages in thread
From: Pavoori, Kiran @ 2003-07-14 17:47 UTC (permalink / raw)
  To: 'drow@mvista.com', 'gdb@sources.redhat.com'

Would like to hear an opinion on this declaration.

namespace N
{
class C 
{
    public:
        ~C(){}
        C() {}
        typedef enum 
        {
                EV_X,
                EV_Y, 
                EV_Z
        } Events;
};
}


Now looking at the above declaration I would access the enum EV_X as
follows:

N::C::EV_X

Is this an acceptable declaration?
Please comment when you get a chance, thank-you
Kiran

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: nested namespace and enum
  2003-07-14 17:47 nested namespace and enum Pavoori, Kiran
@ 2003-07-15  3:39 ` Daniel Jacobowitz
  0 siblings, 0 replies; 2+ messages in thread
From: Daniel Jacobowitz @ 2003-07-15  3:39 UTC (permalink / raw)
  To: Pavoori, Kiran; +Cc: 'gdb@sources.redhat.com'

On Mon, Jul 14, 2003 at 10:46:19AM -0700, Pavoori, Kiran wrote:
> Would like to hear an opinion on this declaration.
> 
> namespace N
> {
> class C 
> {
>     public:
>         ~C(){}
>         C() {}
>         typedef enum 
>         {
>                 EV_X,
>                 EV_Y, 
>                 EV_Z
>         } Events;
> };
> }
> 
> 
> Now looking at the above declaration I would access the enum EV_X as
> follows:
> 
> N::C::EV_X
> 
> Is this an acceptable declaration?
> Please comment when you get a chance, thank-you
> Kiran

This does not work in GDB right now, and will not for at least another
release.  It may also require some compiler changes.  Your C++ is right
though.

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2003-07-15  3:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-07-14 17:47 nested namespace and enum Pavoori, Kiran
2003-07-15  3:39 ` Daniel Jacobowitz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).