Answer the question
In order to leave comments, you need to log in
Enum forward declaration - what am I doing wrong?
I'm trying to make an Enum forward declaration.
I want the enum to belong to SomeClass.
SomeClass.h
class SomeClass
{
public:
enum class InnerEnum : int
{
A,
B,
C
};
}
enum class SomeClass::InnerEnum : int;
class OtherClass
{
private:
SomeClass::InnerEnum mVariable;
};
error: opaque-enum-specifier must use a simple identifier enum class SomeClass::InnerEnum : int;
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question