Micro-optimize qt_section_chunk ctor

Use C++11 move semantics, and the ctor-init-list.

Change-Id: I1a5faa83ef552e8d98ce994edf967770a73cab0e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
bb10
Marc Mutz 2014-08-13 20:53:32 +02:00
parent b53bf377a9
commit 2ad5d62f11
1 changed files with 1 additions and 1 deletions

View File

@ -3966,7 +3966,7 @@ QString QString::section(const QString &sep, int start, int end, SectionFlags fl
class qt_section_chunk {
public:
qt_section_chunk() {}
qt_section_chunk(int l, QString s) { length = l; string = s; }
qt_section_chunk(int l, QString s) : length(l), string(qMove(s)) {}
int length;
QString string;
};