Recursion is already possible indirectly. An alias cannot call itself, but it can call another alias, which in turn can call the first (see this post for details).

The reason direct recursion is disabled is simply that the majority of scripters aren't familiar with recursion and its results. Calling an alias from within itself, by mistake, can give results that novice scripters may not expect or be able to explain (results that are usually much less intuitive than a freezing loop, for example). To those scripters, recursion does "seem to cause more problems than it solves". More advanced scripters who really need recursion can simply do it indirectly, with very little effort.

That said, I wouldn't mind a recursive capability in aliases, as long as it's specified explicitly, like the alias -r { code } that has been suggested before. This way novice scripters are 'protected' while those who need recursion are saved the (very small) extra code/overhead of indirect recursion.

Last edited by qwerty; 02/04/05 02:28 PM.

/.timerQ 1 0 echo /.timerQ 1 0 $timer(Q).com