diff options
| author | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2016-11-23 10:10:55 +0100 |
|---|---|---|
| committer | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2016-11-25 11:32:47 +0000 |
| commit | 840e787175f0cec4714c3941c99c045a9717910d (patch) | |
| tree | 763121944312cb28c53ab611932553c68cbbc08f /src/plugins/debugger/debuggerprotocol.cpp | |
| parent | 90fb7c79d8b0ec47e0ac661fd1185d11a06ba2ee (diff) | |
| download | qt-creator-840e787175f0cec4714c3941c99c045a9717910d.tar.gz | |
Use QString::splitRef() instead of QString::split()
Avoid string allocation where it seems feasible.
Change-Id: I61b23d4ef8a459f5aa77727a75f4e1d2b140da3b
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Diffstat (limited to 'src/plugins/debugger/debuggerprotocol.cpp')
| -rw-r--r-- | src/plugins/debugger/debuggerprotocol.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/debugger/debuggerprotocol.cpp b/src/plugins/debugger/debuggerprotocol.cpp index 46f60b0954..45288cb83c 100644 --- a/src/plugins/debugger/debuggerprotocol.cpp +++ b/src/plugins/debugger/debuggerprotocol.cpp @@ -822,9 +822,9 @@ QString DebuggerCommand::argsToString() const DebuggerEncoding::DebuggerEncoding(const QString &data) { - const QStringList l = data.split(':'); + const QVector<QStringRef> l = data.splitRef(QLatin1Char(':')); - const QString &t = l.at(0); + const QStringRef &t = l.at(0); if (t == "latin1") { type = HexEncodedLatin1; size = 1; |
