C++: Remove hard-coded configuration file name.

Change-Id: Ibe4cc69eafd14dab7707862b1068ce1e21b1d8e0
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com>
This commit is contained in:
Erik Verbruggen
2012-11-28 09:52:19 +01:00
parent d37ee4d1ab
commit cfc1069c78
12 changed files with 31 additions and 26 deletions

View File

@@ -589,6 +589,8 @@ void Preprocessor::State::popTokenBuffer()
--m_tokenBufferDepth;
}
const QString Preprocessor::configurationFileName = QLatin1String("<configuration>");
Preprocessor::Preprocessor(Client *client, Environment *env)
: m_client(client)
, m_env(env)
@@ -1751,7 +1753,7 @@ void Preprocessor::handleIfDefDirective(bool checkUndefined, PPToken *tk)
// the macro is a feature constraint(e.g. QT_NO_XXX)
if (checkUndefined && macroName.startsWith("QT_NO_")) {
if (macro->fileName() == QLatin1String("<configuration>")) {
if (macro->fileName() == configurationFileName) {
// and it' defined in a pro file (e.g. DEFINES += QT_NO_QOBJECT)
value = false; // take the branch