From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/46273 Path: news.gmane.org!not-for-mail From: Hans Hagen Newsgroups: gmane.comp.tex.context Subject: Re: ! Extra \else error Date: Thu, 11 Dec 2008 16:03:47 +0100 Message-ID: <49412BD3.8030400@wxs.nl> References: <200812110650.53610.bntgcontext@wiseguysweb.com> <769ba7780812110605t794abb4bhf84d2c28f5d4e05@mail.gmail.com> <4941210F.8030300@wxs.nl> <200812110740.37327.bntgcontext@wiseguysweb.com> 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 1229008018 13404 80.91.229.12 (11 Dec 2008 15:06:58 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 11 Dec 2008 15:06:58 +0000 (UTC) Cc: ntg-context@ntg.nl To: "Bart C. Wise" Original-X-From: ntg-context-bounces@ntg.nl Thu Dec 11 16:08:01 2008 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by lo.gmane.org with esmtp (Exim 4.50) id 1LAn88-00080R-AT for gctc-ntg-context-518@m.gmane.org; Thu, 11 Dec 2008 16:07:08 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 0D8911FCAF; Thu, 11 Dec 2008 16:05:55 +0100 (CET) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 09592-04-2; Thu, 11 Dec 2008 16:04:37 +0100 (CET) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id F36281FC5D; Thu, 11 Dec 2008 16:04:36 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 958EA1FC54 for ; Thu, 11 Dec 2008 16:04:35 +0100 (CET) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 09592-04 for ; Thu, 11 Dec 2008 16:03:54 +0100 (CET) Original-Received: from mail.pragma-ade.net (dsl-083-247-100-017.solcon.nl [83.247.100.17]) by ronja.ntg.nl (Postfix) with ESMTP id 011931FC5D for ; Thu, 11 Dec 2008 16:03:53 +0100 (CET) Original-Received: from [10.100.8.10] (unverified [10.100.8.10]) by controller-1 (SurgeMail 3.9e) with ESMTP id 16669-1840426 for multiple; Thu, 11 Dec 2008 16:03:51 +0100 User-Agent: Thunderbird 2.0.0.18 (Windows/20081105) In-Reply-To: <200812110740.37327.bntgcontext@wiseguysweb.com> X-Originating-IP: 10.100.8.10 X-Authenticated-User: hagen@controller-1 X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.11 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 X-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:46273 Archived-At: Bart C. Wise wrote: > On Thursday 11 December 2008 07:17:51 am Hans Hagen wrote: >> Zhichu Chen wrote: >>> Hi Bart >>> >>> On Thu, Dec 11, 2008 at 9:50 PM, Bart C. Wise >>> >>> wrote: >>>> When I run the code below (via minimals), I get the following error, >>>> why? >>>> >>>> enter loop >>>> >>>> ! Extra \else. >>>> >>>> \@@plniterate ...\expandafter \@@plniterate \else >>>> >>>> \fi >>>> >>>> \myloop ...by 1 \ifnum \tempcnta >#1\else \repeat >>> I think the loop structure should be: >>> \loop ... \if... ... \repeat >> just use: >> >> \doloop { >> >> \ifwhateveryoulike >> \exitloop >> \fi >> > > Hans, > > Thanks, that works. But shouldn't the other one work as well? Is there > something wrong with the syntax? you cannot use else in plain's loop macro; nor can you use it nested; it's just the way the plain loop macro is defined ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl ----------------------------------------------------------------- ___________________________________________________________________________________ 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 ___________________________________________________________________________________