Fix qAsConst usage.

This commit is contained in:
Andrius Štikonas 2017-10-03 11:19:07 +01:00
parent 63b501f41d
commit e02160d025
1 changed files with 3 additions and 3 deletions

View File

@ -82,7 +82,7 @@ int main( int argc, char **argv )
auto devices = backend->scanDevices(); auto devices = backend->scanDevices();
qDebug() << "Found" << devices.length() << "devices."; qDebug() << "Found" << devices.length() << "devices.";
for (const auto pdev : devices) for (const auto pdev : qAsConst(devices))
{ {
qDebug() << "Device @" << (void *)pdev; qDebug() << "Device @" << (void *)pdev;
qDebug() << " " << pdev->prettyName(); qDebug() << " " << pdev->prettyName();
@ -92,8 +92,8 @@ int main( int argc, char **argv )
<< (partitiontable ? partitiontable->typeName() : QLatin1String("null")) << ')'; << (partitiontable ? partitiontable->typeName() : QLatin1String("null")) << ')';
const auto partitionlist = flatten(partitiontable); const auto partitionlist = flatten(partitiontable);
for (const auto &p : qAsConst(partitionlist)) for (const auto &p : qAsConst(partitionlist))
qDebug() << " " qDebug() << " "
<< p->number() << p->number()
<< p->partitionPath() << p->partitionPath()
<< p->label() << p->label()