help-gplusplus
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Is this legal?


From: red floyd
Subject: Is this legal?
Date: Tue, 29 Jun 2004 17:38:55 -0000
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.6) Gecko/20040113


class A {
public:
  enum E { EN1, EN2, EN3 };
};

class B {
public:
    void f(const char *s, A::E en = A::E::EN1);
};

MSVC 7.1 accepts it, G++ 3.2.2 (3.2.2-3mdk) gives the following error:
`A::E' is not an aggregate type

Is this an error in G++ or in VC?  What does the Holy Standard say?


reply via email to

[Prev in Thread] Current Thread [Next in Thread]