Please enable JavaScript to view this site.

 

Navigation: Messages > Run-Time Messages > Token Syntax

Too many levels of token recursion !

Scroll Prev Up Next More

This message occurs if the conversion of a token (mentioned in the message title) generates more than 50 recursive calls to itself.

 

It means that one of your tokens is replaced by text containing other tokens, and that these tokens generate other tokens which generate other tokens, and so on and so forth, for more than 50 times.

 

This message is similar conceptually to the message due to too many levels of iteration, but is technically quite different in its origin.

 

The message about too many levels of iteration could be generated by a token which is replaced by 1001 simple tokens, such as [d] whose replacement is simple. It is a message about the number of tokens generated by the token causing the message.

The present message could be issued by a token which is replaced by a single token, but a single token that is then replaced by another single token, itself replaced by yet another single token, for more than 50 times. This is a message about the complexity or the number of times a token needs to be processed to get its result.

 

You can use the maximum recursion setting to change the default value of 50, but it should almost never be necessary, as recursion of the token conversion function is much rarer than token conversion iteration, and this message is almost always the sign of an infinite loop in your script.

 


Topic 173360, last updated on 22-Mar-2021