Prefer QVector to QList on local variables. Iterate with qAsConst on containers that should not change.