ErrorNames is not implemented by vector<string> but *char[]

This commit is contained in:
numatrumpet
2014-09-08 16:36:28 +09:00
parent 8f5d3f8e80
commit 003368429f
3 changed files with 4 additions and 14 deletions

View File

@@ -39,8 +39,6 @@ distribution.
# include <cstdlib>
# include <cstring>
# include <cstdarg>
# include <vector>
# include <string>
#endif
/*
@@ -512,14 +510,12 @@ enum XMLError {
};
#undef FF
#if __cplusplus > 199711LL
#define FF(X) #X,
const std::vector<std::string> ErrorNames = {
static const char *ErrorNames[] = {
FOR_EACH(FF)
"OUT_OF_RANGE"
};
#undef FF
#endif
#undef FOR_EACH
@@ -601,7 +597,7 @@ public:
static bool ToDouble( const char* str, double* value );
// converts XMLError to strings
static std::string ToErrorName( const XMLError errorID );
static const char* ToErrorName( const XMLError errorID );
};