On Sun, 23 Aug 2009, Hans Hagen wrote:
Aditya Mahajan wrote:
Hi,
Guess what happens when you run this with xetex
\starttext\recurselevel\stoptext
This is a side effect of the definition of \dofastrecurse. After using \dofastrecurse, the default value of recurselevel is \number\fastrecursecounter rather than 0. I don't think that this will have any side effects.
no, it's just the last value; of course i can set it to zero
recurselevel is also known inside \doloop so there it makes sense to have it afterrwards (or when using \exitloop in any case)
Both \dorecurse and \doloop leave the value of \recurselevel to its previous value. \dofastrecurse does not and sets it to the last value. \starttext \recurselevel \dorecurse{6}{Hello } \recurselevel \doloop{\ifnum\recurselevel>6\relax \exitloop\else again \fi} \recurselevel \dofastrecurse{1}{6}{1}{and again} \recurselevel \stoptext I do not think that any change is needed (One shouldn't use \recurselevel outside a recursion macro anyways). I was just surprised to find that recurselevel was defaulting to such a weird value in xetex. Aditya