Received: from mout.gmx.net (mout.gmx.net [212.227.15.19]) by h1439878.stratoserver.net (8.14.2/8.14.2/Debian-2build1) with ESMTP id r6GJTq0j009760 for ; Tue, 16 Jul 2013 21:29:53 +0200 Received: from relay.uni-heidelberg.de ([129.206.100.212]) by mx-ha.gmx.net (mxgmx005) with ESMTP (Nemesis) id 0MQtdG-1UaW0b13h0-00UNgo for ; Tue, 16 Jul 2013 21:29:47 +0200 Received: from listserv.uni-heidelberg.de (listserv.uni-heidelberg.de [129.206.100.94]) by relay.uni-heidelberg.de (8.14.1/8.14.1) with ESMTP id r6GJRFcb021936 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 16 Jul 2013 21:27:16 +0200 Received: from listserv.uni-heidelberg.de (listserv.uni-heidelberg.de [127.0.0.1]) by listserv.uni-heidelberg.de (8.13.8/8.13.8) with ESMTP id r6GHbvwO008273; Tue, 16 Jul 2013 21:27:14 +0200 Received: by LISTSERV.UNI-HEIDELBERG.DE (LISTSERV-TCP/IP release 16.0) with spool id 10313929 for LATEX-L@LISTSERV.UNI-HEIDELBERG.DE; Tue, 16 Jul 2013 21:27:14 +0200 Received: from relay.uni-heidelberg.de (relay.uni-heidelberg.de [129.206.100.212]) by listserv.uni-heidelberg.de (8.13.8/8.13.8) with ESMTP id r6GJREYE025309 for ; Tue, 16 Jul 2013 21:27:14 +0200 Received: from mail-ob0-f176.google.com (mail-ob0-f176.google.com [209.85.214.176]) by relay.uni-heidelberg.de (8.14.1/8.14.1) with ESMTP id r6GJR6kf021889 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=FAIL) for ; Tue, 16 Jul 2013 21:27:10 +0200 Received: by mail-ob0-f176.google.com with SMTP id v19so1251657obq.35 for ; Tue, 16 Jul 2013 12:27:06 -0700 (PDT) X-Received: by 10.60.98.73 with SMTP id eg9mr3594640oeb.70.1374002826457; Tue, 16 Jul 2013 12:27:06 -0700 (PDT) MIME-Version: 1.0 Received: by 10.76.68.99 with HTTP; Tue, 16 Jul 2013 12:26:46 -0700 (PDT) References: Content-Type: text/plain; charset=ISO-8859-1 Message-ID: Date: Tue, 16 Jul 2013 21:26:46 +0200 Reply-To: Mailing list for the LaTeX3 project Sender: Mailing list for the LaTeX3 project From: Michiel Helvensteijn Subject: Re: Pointers [was: Request for argument specifiers which generate unique csnames] To: LATEX-L@LISTSERV.UNI-HEIDELBERG.DE In-Reply-To: Precedence: list List-Help: , List-Unsubscribe: List-Subscribe: List-Owner: List-Archive: Envelope-To: X-GMX-Antispam: 0 (Mail was not recognized as spam); Detail=V3; X-GMX-Antivirus: 0 (no virus found) X-UI-Filterresults: notjunk:1;V01:K0:6FH1CHTv/es=:56yECHaYNoV4qKFlaFzA5+ rfu5NGHbGY6LqauN9eEZH2U5EPzwhDYq6QEoolU1I8kVMi1T7jpZZMj4C+N8Eft86dcr/YJ QcAf5sWwkalw2jffUY6RW1EMCRTO0JeGjf70qtM0TNX076C72aDI47XFJiJg+TnWk0kJTDB 6BBa50QfXzZtH3DoeeQgmvGjeNsEmtdq1YYYmDc4uCQH4qs23KosVpgZ0eSNhFje8/Ib1zE dxqr91mTu9mJemdwzP0MFV4vlT2jqXx5gRCwp2NpShWaTax/+L1RwKfKrkuDnVh0HLlBLba KM7Ya6pERbx8a6b5vGQa9nQh2UqTjLqJWpiJin6B/02Z5NirCIm8V/xK90AcfmJs7vjkKPc wTeHA/Q1erZPfouDik7zbXwhI4ruzzAwMgWVUE9wXPp079guec3Rxbw2zZXtJH5bhZbbQjc ds/69ib8gsN2HovnHc0Fr2gN9WPEsVJXQzE5oXfqheEGgf5K7/78CkVQndGOBigVKCgZBLz HDFNGf2Db7gZwPDENCTGuqwk2tMzy92xX+/XgY3BPrLP0Du3umueZcdhtnkgQdkBmH4NYXK bK2ItQmz+9S4fEW0+hGGNXi+LwR+ReEURysxk+4JAJr4NHUKgmtLFpKo2UVYRDoIFwtFeKe 6l2bjC31rhZLtVt0ABzwtnkJPJtQhhfERSerLQH5OxzQZKMXyXqNT1GobFcQjX2pKbOzp8r nP9DsKU7liuMHn5AOmh75RejGmS/uZzZiqFTUKuzov93ryAkkH2wC8kqeUzMKJvF1QqxHsF xf6c2BuvBijiZ4qhOeiW//+dPvN7K8maBO571tGYxWsHwI9mIgj9T077D/7NHpVs57uYMAI cxxfLSgJ4cjxgzmOSLqzfWcTb08nO6sym+8OWy0mhHmFMCEx+CJtjGAFHsKbn2prkYKfo7t aSs1qUUBnmDI2hpy/Ahjqujupg9eTJCKTjvc/2X4WVgu9d7Bl94oBzm9+t07k9evvudQa/o XCNARAX/ArnBXa9hgyC+7RGUReR2V3voPdyF/BOuw26VMsMMugo5GFG7DI/8tlCnxmnhCgV mm+yfLBl4aW1DmMCE2x8nrWhm/mU1gdLMClHB0V55+i2ea2icr/0tNvQ2A7ZuDG0+19DDPY Esdpup47yX/NAi5woMf0e1/zW5RI3Z4sO0VuqvsvkgKtqDhKXpROojHT65XiruLUvCGZkkz Udz6LwH0J2YSmg6HavVSEE5yCHZLObH6lPZ920ocTgW/uUdruu9ay1+JNtOuwzcfkfZPaHD DAtzCT7Zi6ILMwc3CO7lDhwBg8czmOBgZdoz5GT3eOGh+ju15lcKp4ru/i6p53KCAey2TAj sBs+SneaReZvufPWFk6mJ15VwsxARVDTWs8usxluTA1u4/PeTQJvE1/OlcedFp5sFgIWivh XafvIyKaGoWmFV+NCYQdbFnxSuZrXjCWfGYfbTpMgxaIBr9OC7wZaP5q6HqGPYAlstFgpvk 88iG7/EvCJbEGXSukRybakv7o1+Kbl3fNFcssJlcpEdXQ4jZZcr+4gJMLLbYEI4e/MEzGTk mMgghnK1LEcUQpwc2nguFnUAHNzFXrzG0Vdgvepq7QrTPBkblychG89un2A= X-UI-Loop:V01:61GGEMgaGmI=:pbN8nfSnix3bK+lU0PTPHATgVWzYFzhqdr05CoEENwQ= Status: R X-Status: X-Keywords: X-UID: 7250 On Tue, Jul 16, 2013 at 7:56 PM, Bruno Le Floch wrote: > Actually, this slight issue hints at a memory leak waiting to happen: > TeX will never be able to know when all mentions of the unique name > are gone, hence that name (and the associated contents) will need to > remain forever. This does not seem very safe. Well, it's "safe", but it leaks memory, as you say. I do wonder how much this matters in practice, given that LaTeX runs short batch-jobs rather than continuous processes. But it is a valid concern. > or one could write a package providing \pointer_arg:Nn (or something similar) > > \pointer_arg:Nn \foo:n { ab\cd } Indeed! A family of `\exp_args` like commands is probably the best way to go. One of the arguments is, as you say, that the same library can provide facilities for garbage-collection. Another argument, which just occurred to me, is that I'll now have the full set of expl3 argument specifiers at my disposal for expanding the value before putting it in the pointer. I will write this library at some point. I'm currently quite busy, though. Thanks! -- www.mhelvens.net