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 r29Bwwic014324 for ; Sat, 9 Mar 2013 12:58:59 +0100 Received: from relay.uni-heidelberg.de ([129.206.100.212]) by mx-ha.gmx.net (mxgmx110) with ESMTP (Nemesis) id 0LhBcJ-1Uagrj37mJ-00oXWS for ; Sat, 09 Mar 2013 12:58:52 +0100 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 r29BuQwm017054 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 9 Mar 2013 12:56:26 +0100 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 r298TJQc023477; Sat, 9 Mar 2013 12:56:26 +0100 Received: by LISTSERV.UNI-HEIDELBERG.DE (LISTSERV-TCP/IP release 16.0) with spool id 8154566 for LATEX-L@LISTSERV.UNI-HEIDELBERG.DE; Sat, 9 Mar 2013 12:56:25 +0100 Received: from relay2.uni-heidelberg.de (relay2.uni-heidelberg.de [129.206.210.211]) by listserv.uni-heidelberg.de (8.13.8/8.13.8) with ESMTP id r29BuPNi015330 for ; Sat, 9 Mar 2013 12:56:25 +0100 Received: from mail-ob0-f175.google.com (mail-ob0-f175.google.com [209.85.214.175]) by relay2.uni-heidelberg.de (8.13.8/8.13.8) with ESMTP id r29BtluT023403 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=FAIL) for ; Sat, 9 Mar 2013 12:55:50 +0100 Received: by mail-ob0-f175.google.com with SMTP id uz6so2007709obc.20 for ; Sat, 09 Mar 2013 03:55:46 -0800 (PST) X-Received: by 10.182.147.2 with SMTP id tg2mr4353580obb.47.1362830146857; Sat, 09 Mar 2013 03:55:46 -0800 (PST) MIME-Version: 1.0 Received: by 10.76.22.6 with HTTP; Sat, 9 Mar 2013 03:55:25 -0800 (PST) X-Google-Sender-Auth: FHM0Oo7P-tG7aaSKv3c86er4K20 Content-Type: text/plain; charset=ISO-8859-1 Message-ID: Date: Sat, 9 Mar 2013 12:55:25 +0100 Reply-To: Mailing list for the LaTeX3 project Sender: Mailing list for the LaTeX3 project From: Michiel Helvensteijn Subject: Bug + fix for \prop_map_tokens:Nn To: LATEX-L@LISTSERV.UNI-HEIDELBERG.DE 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:KY7gDY1eWnw=:nfWaDegYrDKRJ98+MyCbcT M+U5HZ/AfnBHi8cJ64h/4XzePCdGlbKQABa/yrfsvji9A5mnU/7++b7cydGvFgagae6v+By AGpCIJXeUspDOtMtQNjm9Pkxnxl4newxe6hMvTyCDIXCkyg7+NLNSVgUalyBOqiU0vJvrbz 8DOQ3UZs9MqESK6Y9eIF4nSaD5wuyROMR/cxivVbrAJecyw0PDQD+rMdsaFNRR++u1nR9zI uEO3ZbCstnExLXH07hRFyR1hJDCBS/5IgwJcesQHCh4hGvx9+HTigcF1wO/ttgyF+K/xY3x ZFcv3tVV7tJdmpDx+ON9DclVFKbPNZ4UKDqzEOEuqdYOybV1BQf2fXIOBimzN7oVRJhBdYO pttugjJDkxs3+IgHvFLzJL4IGF3IMUu0LsOyf4Y4NiNhiRHL0gMolxfol84dUrpT3Whu++h OkBbwYVayGHyYnfJww+vcrbRWJ37Y7QrD/A0eCFJL94SoNqAhJNgrqaUQl0/pOlWNWi24e+ PPImrtRVRw+hv5YbZXbVJ/miayx0LWIGh35lJpytNN6HePEmiIWmpEFc3aZb8De6sUD63kP ipK3bRQ2ddPFr5czFNo0Vr5g7B6tFIoMhZgllCxv0cOg4/NcbfmKn1gQSWNX/zwzIt0BS0u UQ1jfJm4+LLDHI8gUkpzm3wrljtOUvyP9n85Vhe1d5zK+/GqIXMRPmH4qlJXbtjkp8xH3Hc KOESNgmYlCqa1xZADZNm3D2VhnTBNoCQlpfWIz+3qjH3uOlDi+2+ByOZiCvgF8QAEE8ANJl 1FutcMjnHvLPEpD6QxzI4pPwPETrQYuWY+hc8REQ7nwtsdH/auMbN/vcUFZ8rgconkhqA6w w1uFpPqurOSKclcilP8udxwcITrIoSez/fEPT/x+SE0+LeVtn3FCGed5ES/td0Y77L98fJo pZx3Id9J2MZDGQa981LqTpYsyoFQhlopE4OjU4j2K0Tz8SNo26RZ/Zg68+fRQPQ6uar0zgR vHtV6neTARmxZKVoAU1aJ6PpcJNKpZSNwIjvmxSc3VPtvS2EkB9QoIX+4byQpZ6oyAsjp6X 5YfFHj+ZKm2GTk9LlDrUOs2wSFw9yTN+TdBU4QVTxxOUEznbipjmhTc7YbnjDxnFDBOCEM7 uZYsrZ1oD2qa5az7V/6rgO0+r4NWky3xs5H6dQcmzy+VJNLn38ks9JIZ5wvv/uXVI/sD5vw KVtrl+kIk635X1ZLz7UvJwRyU7S9z0QnCzaBHXVPuPYJ0w68d8jAVA+ZaCrCDWtlr0WSHIF 3ZRiq2IgSFXcJkUMCnbFEIN8Tk0yK4ffk/BWSC93dnPN0yk0fUfThr3eSQJIfRD9uYMCh5e YzU0hnGgqy4I6QyKjnFa3tec4FJfcdpJBZBiXTX35N6N8xOeC67pWiA3Hs1/ZcQtIpxCVOg 8XgVEAFHg= X-UI-Loop:V01:uPo8+om3+GA=:BmwrnUIR6E3Zcl8jt5YR8vx+06HnUlX+4WS5MQuCszs= Status: R X-Status: X-Keywords: X-UID: 7184 Hi all, I encountered a bug in the \prop_map_tokens:Nn function in l3candidates.dtx. Here's a not-working minimal example: ---------------------------------------- \ExplSyntaxOn \cs_set:Nn \test_mapper:nn { (#1,~#2)~ } \prop_new:N \testprop \prop_put:Nnn \testprop {1} {v1} \prop_put:Nnn \testprop {222} {v2} \prop_put:Nnn \testprop {3} {v3} \prop_put:Nnn \testprop {4} {v4} \prop_map_tokens:Nn \testprop { \test_mapper:nn } \ExplSyntaxOff ---------------------------------------- The output will be: ---------------------------------------- (1, v1)2 ---------------------------------------- It only processes single-token keys correctly. At the first multi-token key, everything except for its first two tokens are processed directly, then the rest of the list is skipped. Here's the fix for l3candidates.dtx: ---------------------------------------- \cs_new:Npn \@@_map_tokens:nwn #1 \q__prop #2 \q__prop #3 { \__quark_if_recursion_tail_break:nN {#2} \prop_map_break: \use:n {#1} {#2} {#3} \@@_map_tokens:nwn {#1} } ---------------------------------------- It just changes the tail-break test from :NN to :nN and adds braces around #2. Cheers! -- www.mhelvens.net