corelib: settings - make qsettings.cpp unity buildable
Both qsettings.cpp and qjsonparser.cpp defined Space in the global namespace. Hiding it in one of them in an implementation namespace resolves the name clash. Pick-to: 6.7 6.6 6.5 Change-Id: I8dd1244f80d87f3908597ed82c8e41b49b7b916c Reviewed-by: Marc Mutz <marc.mutz@qt.io>bb10
parent
3ec9331c34
commit
4ff65f0e56
|
|
@ -328,7 +328,6 @@ qt_internal_add_module(Core
|
|||
text/qstringconverter.cpp # enum Data
|
||||
tools/qcryptographichash.cpp # KeccakNISTInterface/Final
|
||||
io/qdebug.cpp # undef qDebug
|
||||
io/qsettings.cpp # Space (also in qjsonparser.cpp)
|
||||
NO_PCH_SOURCES
|
||||
compat/removed_api.cpp
|
||||
global/qsimd.cpp
|
||||
|
|
|
|||
|
|
@ -1518,6 +1518,8 @@ void QConfFileSettingsPrivate::syncConfFile(QConfFile *confFile)
|
|||
}
|
||||
}
|
||||
|
||||
namespace SettingsImpl {
|
||||
|
||||
enum { Space = 0x1, Special = 0x2 };
|
||||
|
||||
static const char charTraits[256] =
|
||||
|
|
@ -1544,10 +1546,15 @@ static const char charTraits[256] =
|
|||
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
|
||||
};
|
||||
|
||||
} // namespace SettingsImpl
|
||||
|
||||
using SettingsImpl::charTraits;
|
||||
|
||||
bool QConfFileSettingsPrivate::readIniLine(QByteArrayView data, qsizetype &dataPos,
|
||||
qsizetype &lineStart, qsizetype &lineLen,
|
||||
qsizetype &equalsPos)
|
||||
{
|
||||
using namespace SettingsImpl;
|
||||
qsizetype dataLen = data.size();
|
||||
bool inQuotes = false;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue