$diff = $dt->diff($start);
$start = $diff->days;
$set = array();
for ($i = $start, $k = 0; $k < 7; $k++) {
$set[] = $i;
++$i; // Increment on type bool has no effect, this will change in the next major version of PHP
if (null !== $dtInfo && null !== $rule && $dtInfo->wDayMask[$i] == $rule->getWeekStartAsNum()) {
break;
}
}