Received: from mail.proteosys.com ([213.139.130.197]) by nummer-3.proteosys with Microsoft SMTPSVC(6.0.3790.3959); Tue, 4 Aug 2009 09:12:03 +0200 Received: by mail.proteosys.com (8.14.3/8.14.3) with ESMTP id n747C2Ec028531 for ; Tue, 4 Aug 2009 09:12:02 +0200 Received: from listserv.uni-heidelberg.de (listserv.uni-heidelberg.de [129.206.100.94]) by relay2.uni-heidelberg.de (8.13.8/8.13.8) with ESMTP id n7477U5m032612 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 4 Aug 2009 09:07:31 +0200 Received: from listserv.uni-heidelberg.de (localhost.localdomain [127.0.0.1]) by listserv.uni-heidelberg.de (8.13.1/8.13.1) with ESMTP id n73M1BFt011091; Tue, 4 Aug 2009 09:07:30 +0200 Received: by LISTSERV.UNI-HEIDELBERG.DE (LISTSERV-TCP/IP release 15.5) with spool id 294823 for LATEX-L@LISTSERV.UNI-HEIDELBERG.DE; Tue, 4 Aug 2009 09:07:30 +0200 Received: from relay.uni-heidelberg.de (relay.uni-heidelberg.de [129.206.100.212]) by listserv.uni-heidelberg.de (8.13.1/8.13.1) with ESMTP id n7477TRZ017835 for ; Tue, 4 Aug 2009 09:07:29 +0200 Received: from ueamailgate02.uea.ac.uk (ueamailgate02.uea.ac.uk [139.222.131.185]) by relay.uni-heidelberg.de (8.14.1/8.14.1) with ESMTP id n7477JB2009541 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Tue, 4 Aug 2009 09:07:22 +0200 Received: from ueams02.uea.ac.uk (ueams02.uea.ac.uk [139.222.131.131]) by ueamailgate02.uea.ac.uk (8.13.1/8.13.1) with ESMTP id n7477Ipk027583 for ; Tue, 4 Aug 2009 08:07:19 +0100 Received: from [139.222.202.49] by ueams02.uea.ac.uk with esmtp (Exim 4.69) (envelope-from ) id 1MYE78-0000gU-Ep for LATEX-L@LISTSERV.UNI-HEIDELBERG.DE; Tue, 04 Aug 2009 08:07:14 +0100 User-Agent: Thunderbird 2.0.0.22 (Windows/20090605) MIME-Version: 1.0 References: <4A720566.80504@morningstar2.co.uk> <5BD2F1CD-3A4D-4204-889D-7E7CDA38F364@gmail.com> <4A740307.5000703@morningstar2.co.uk> <4A77667A.5080400@residenset.net> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Canit-CHI2: 0.00 X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN, outgoing) X-CanItPRO-Stream: UEA:outgoing (inherits from UEA:default,base:default) X-Canit-Stats-ID: 27426193 - 271aca1ef7b2 X-Scanned-By: MIMEDefang 2.65 on 213.139.130.197 X-Scanned-By: CanIt (www . roaringpenguin . com) on 139.222.131.185 Message-ID: <4A77DE28.90808@morningstar2.co.uk> Date: Tue, 4 Aug 2009 08:07:20 +0100 Reply-To: Mailing list for the LaTeX3 project Sender: Mailing list for the LaTeX3 project From: Joseph Wright Subject: Re: \tl_add_braces:N ? To: LATEX-L@LISTSERV.UNI-HEIDELBERG.DE In-Reply-To: <4A77667A.5080400@residenset.net> Precedence: list List-Help: , List-Unsubscribe: List-Subscribe: List-Owner: List-Archive: X-ProteoSys-SPAM-Score: -6.599 () BAYES_00,RCVD_IN_DNSWL_MED Return-Path: owner-latex-l@LISTSERV.UNI-HEIDELBERG.DE X-OriginalArrivalTime: 04 Aug 2009 07:12:03.0062 (UTC) FILETIME=[DDD0D960:01CA14D2] Status: R X-Status: X-Keywords: X-UID: 5805 Lars Hellström wrote: > Hmm... IMHO, the awkwardness here is partly due to using a list-oriented > API to construct what really is a tree (even though we must _store_ it > in linearised form, as a list). Well, things do start of in a more structured format (I'm using a property list to put each "part" together, but in the end I need something TeX can print in one go). > In order to respect this tree structure, > I'd probably rather do the last two steps as > > \def\l_tmpa#1{ > \def\l_tmpa_tl{10^{#1}} > } > \expandafter\l_tmpa \expandafter{ \l_tmpa_tl} % Or use \exp_args:No > > if you pardon the primitives[*]. Of course, if the material isn't > fragile -- the given example isn't -- then a single (protected) \edef is > even simpler. In the LaTeX2e version, I do use \protected@edef. However, I'm trying to avoid this method, if possible, as it does not make the flow as clear. With something like \tl_put_right:NV, the point that the contents of one variable is being added to another variable is clearer, I think. > [*] I'm starting to doubt I'll ever manage a transition to l3names, > myself... Sure, some parts are really nifty, but other parts seem bent > on establishing a computational model for LaTeX that I'm not quite > comfortable with. I guess this very much depends what you want to achieve. For what I'm working on, I need lots of higher-level stuff such as loops, comparisons and the like. It's at that level that LaTeX3 is useful to me, as I can use the built-in ones rather than code them myself. -- Joseph Wright