rvalue functions for containers

This commit is contained in:
2020-07-30 22:26:05 +03:00
parent a12e63e569
commit 79e17b48b8
10 changed files with 61 additions and 41 deletions

View File

@@ -35,6 +35,7 @@ int main() {
#include "picodeparser.h"
int main() {
piDebug = false;
PIString t("1234567890-=");
double min = -1, max = -1, mean = 0;
for (int i = 0; i < 50; ++i) {
PITimeMeasurer tm;
@@ -43,10 +44,10 @@ int main() {
PIStringList sl;
sl.reserve(500000);
for (int i = 0; i < 500000; ++i) {
//PIString s("1234567890-=");
//sl << s;
//sl.push_back(PIString("1234567890-="));
sl << PIString("1234567890-=");
// PIString s(t);
// sl << s;
sl.push_back(PIString(t));
//sl << PIString("1234567890-=");
}
double ms = tm.elapsed_m();
if (min < 0) min = ms;