fixes for C++11/14

This commit is contained in:
Günter Obiltschnig
2020-01-14 10:49:47 +01:00
parent d39042ba77
commit 450089d5e6
4 changed files with 40 additions and 4 deletions

View File

@@ -40,7 +40,12 @@ public:
typedef std::vector<EnumValue*> Values;
typedef Values::const_iterator Iterator;
Enum(const std::string& name, NameSpace* pNameSpace);
enum Flags
{
ENUM_IS_CLASS = 0x01 // C++11 enum class
};
Enum(const std::string& name, NameSpace* pNameSpace, int flags = 0);
/// Creates the Enum.
///
/// If name is the empty string, an internal name
@@ -59,6 +64,8 @@ public:
Iterator end() const;
/// Returns an iterator for iterating over the Enum's EnumValue's.
int flags() const;
Symbol::Kind kind() const;
std::string toString() const;
@@ -67,10 +74,20 @@ protected:
private:
Values _values;
int _flags;
static int _count;
};
//
// inlines
//
inline int Enum::flags() const
{
return _flags;
}
} } // namespace Poco::CppParser