use foreach() for iteration in QDBusMetaObjectGenerator::parseProperties()

Signed-off-by: Ivailo Monev <xakepa10@laimg.moc>
This commit is contained in:
Ivailo Monev 2020-04-09 07:27:43 +00:00
parent a05e01b205
commit dcfd6373a5

View file

@ -316,10 +316,7 @@ void QDBusMetaObjectGenerator::parseSignals()
void QDBusMetaObjectGenerator::parseProperties() void QDBusMetaObjectGenerator::parseProperties()
{ {
QDBusIntrospection::Properties::ConstIterator prop_it = data->properties.constBegin(); foreach (const QDBusIntrospection::Property &p, data->properties) {
QDBusIntrospection::Properties::ConstIterator prop_end = data->properties.constEnd();
for ( ; prop_it != prop_end; ++prop_it) {
const QDBusIntrospection::Property &p = *prop_it;
Property mp; Property mp;
Type type = findType(p.type.toLatin1(), p.annotations); Type type = findType(p.type.toLatin1(), p.annotations);
if (type.id == QVariant::Invalid) if (type.id == QVariant::Invalid)