From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/52524 Path: news.gmane.org!not-for-mail From: Aditya Mahajan Newsgroups: gmane.comp.tex.context Subject: Re: An interesting default for recurselevel in xetex Date: Sun, 23 Aug 2009 15:56:09 -0400 (EDT) Message-ID: References: <4A911FE9.7070405@wxs.nl> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1251057404 29134 80.91.229.12 (23 Aug 2009 19:56:44 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 23 Aug 2009 19:56:44 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Sun Aug 23 21:56:37 2009 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.50) id 1MfJB7-0006yp-NN for gctc-ntg-context-518@m.gmane.org; Sun, 23 Aug 2009 21:56:37 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id BAD9FC9AC7; Sun, 23 Aug 2009 21:56:36 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id u2EAxW6v8YtN; Sun, 23 Aug 2009 21:56:32 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id B467DC9AAF; Sun, 23 Aug 2009 21:56:31 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 76271C9AAF for ; Sun, 23 Aug 2009 21:56:29 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id j4F9ZZnd82M4 for ; Sun, 23 Aug 2009 21:56:26 +0200 (CEST) Original-Received: from skycaptain.mr.itd.umich.edu (smtp.mail.umich.edu [141.211.93.160]) by balder.ntg.nl (Postfix) with ESMTP id 06515C9A9C for ; Sun, 23 Aug 2009 21:56:25 +0200 (CEST) Original-Received: FROM [192.168.2.8] (c-76-28-88-45.hsd1.ct.comcast.net [76.28.88.45]) By skycaptain.mr.itd.umich.edu ID 4A919EE7.ED33D.7336 ; Authuser adityam; 23 Aug 2009 15:56:24 EDT In-Reply-To: <4A911FE9.7070405@wxs.nl> User-Agent: Alpine 2.00 (LNX 1167 2008-08-23) X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:52524 Archived-At: 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 ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________