Skip to content

Instantly share code, notes, and snippets.

@nicklewis
Created March 28, 2018 17:56
Show Gist options
  • Save nicklewis/6aa0494f0560f8e1142cfeaf140f2acc to your computer and use it in GitHub Desktop.
Save nicklewis/6aa0494f0560f8e1142cfeaf140f2acc to your computer and use it in GitHub Desktop.
recur module (PUP-8610)
plan recur() {
recur::recurf(0, 0)
}
function recur::recurf($i, $time) {
$now = now()
$delta = $now - $time
notice("iteration ${i}: ${delta}")
if $i < 250 {
recur::recurf($i + 1, $now)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment