good chemistry is complicated, and a little bit messy -LW |
|
PerlMonks |
Re: Recursively executed function in regex RHS, AKA "wait, why does this work?"by choroba (Cardinal) |
on Oct 21, 2014 at 11:34 UTC ( [id://1104560]=note: print w/replies, xml ) | Need Help?? |
Calling a function from the function itself is called "recursion". It's in fact a loop in disguise, in this case it loops until there is no include element in the replacement part. Each include element calls the function again until there are no such elements, then all the functions return. Read more on recursion.
لսႽ† ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ
In Section
Seekers of Perl Wisdom
|
|