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
parent
b53bf377a9
commit
2ad5d62f11
|
|
@ -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;
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in New Issue