Remove QT_STATIC_CONST

This macro is no longer used. It was introduced probably by mistake,
due to MSVC not following the strict string requirement of the C and
C++ standards by default (you can assign a string literal to a
non-const char*).

Change-Id: I4b221dd435191b0eea689dbed35915cf3206648b
Reviewed-by: Martin Smith <martin.smith@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
This commit is contained in:
Thiago Macieira 2014-06-19 12:30:32 -07:00
parent 1d111091b5
commit 11c30f9705
5 changed files with 4 additions and 16 deletions

View File

@ -1015,18 +1015,6 @@
# define Q_DECL_CONST_FUNCTION Q_DECL_PURE_FUNCTION
#endif
/*
Workaround for static const members on MSVC++.
*/
#if defined(Q_CC_MSVC)
# define QT_STATIC_CONST static
# define QT_STATIC_CONST_IMPL
#else
# define QT_STATIC_CONST static const
# define QT_STATIC_CONST_IMPL const
#endif
/*
Proper for-scoping in MIPSpro CC
*/

View File

@ -242,7 +242,7 @@ QStringList MetaStack::getExpanded(const Location& location)
return top().accum;
}
QT_STATIC_CONST_IMPL QString Config::dot = QLatin1String(".");
const QString Config::dot = QLatin1String(".");
bool Config::debug_ = false;
bool Config::generateExamples = true;
QString Config::overrideOutputDir;

View File

@ -141,7 +141,7 @@ public:
static void pushWorkingDir(const QString& dir);
static QString popWorkingDir();
QT_STATIC_CONST QString dot;
static const QString dot;
static bool generateExamples;
static QString installDir;

View File

@ -52,7 +52,7 @@
QT_BEGIN_NAMESPACE
QT_STATIC_CONST_IMPL Location Location::null;
const Location Location::null;
int Location::tabSize;
QString Location::programName;

View File

@ -90,7 +90,7 @@ public:
void fatal(const QString& message,
const QString& details = QString()) const;
QT_STATIC_CONST Location null;
static const Location null;
static void initialize(const Config& config);
static void terminate();