Received: from mail.proteosys.com ([213.139.130.197]) by nummer-3.proteosys with Microsoft SMTPSVC(6.0.3790.3959); Mon, 10 Aug 2009 09:44:39 +0200 Received: by mail.proteosys.com (8.14.3/8.14.3) with ESMTP id n7A7ie2M005084 for ; Mon, 10 Aug 2009 09:44:41 +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 n7A7cv11025143 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 10 Aug 2009 09:38:57 +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 n79M1IFX014993; Mon, 10 Aug 2009 09:38:56 +0200 Received: by LISTSERV.UNI-HEIDELBERG.DE (LISTSERV-TCP/IP release 15.5) with spool id 293652 for LATEX-L@LISTSERV.UNI-HEIDELBERG.DE; Mon, 10 Aug 2009 09:38:56 +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 n7A7cul1025200 for ; Mon, 10 Aug 2009 09:38:56 +0200 Received: from rv-out-0708.google.com (rv-out-0708.google.com [209.85.198.246]) by relay.uni-heidelberg.de (8.14.1/8.14.1) with ESMTP id n7A7cpKx002302 for ; Mon, 10 Aug 2009 09:38:54 +0200 Received: by rv-out-0708.google.com with SMTP id c5so771665rvf.10 for ; Mon, 10 Aug 2009 00:38:50 -0700 (PDT) Received: by 10.140.177.15 with SMTP id z15mr877858rve.222.1249889930602; Mon, 10 Aug 2009 00:38:50 -0700 (PDT) Received: from ?129.127.15.244? ([129.127.15.244]) by mx.google.com with ESMTPS id l31sm23115431rvb.24.2009.08.10.00.38.47 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 10 Aug 2009 00:38:49 -0700 (PDT) Content-Type: multipart/signed; boundary=Apple-Mail-1-999783362; micalg=sha1; protocol="application/pkcs7-signature" Mime-Version: 1.0 (Apple Message framework v935.3) References: <4A7D7AA3.9030309@morningstar2.co.uk> <9B845608-EF5E-4395-B12F-51EE964A51C6@gmail.com> <4A7FC911.7010602@morningstar2.co.uk> X-Mailer: Apple Mail (2.935.3) X-Spam-Whitelist: Message-ID: Date: Mon, 10 Aug 2009 17:08:42 +0930 Reply-To: Mailing list for the LaTeX3 project Sender: Mailing list for the LaTeX3 project From: Will Robertson Subject: Re: Should \ExplSyntax(On/Off) be \protected? To: LATEX-L@LISTSERV.UNI-HEIDELBERG.DE In-Reply-To: <4A7FC911.7010602@morningstar2.co.uk> Precedence: list List-Help: , List-Unsubscribe: List-Subscribe: List-Owner: List-Archive: X-ProteoSys-SPAM-Score: -6.599 () BAYES_00,RCVD_IN_DNSWL_MED X-Scanned-By: MIMEDefang 2.65 on 213.139.130.197 Return-Path: owner-latex-l@LISTSERV.UNI-HEIDELBERG.DE X-OriginalArrivalTime: 10 Aug 2009 07:44:39.0370 (UTC) FILETIME=[6A5842A0:01CA198E] Status: R X-Status: X-Keywords: X-UID: 5852 --Apple-Mail-1-999783362 Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit On 10/08/2009, at 4:45 PM, Joseph Wright wrote: > 1) Design functions which clearly are expandable (such as \IfBooleanTF > or the version of \IfNoValue in xparse-alt): these should left alone > as > they will behave "nicely". > > 2) Design functions which are not expandable (at least under pdfTeX or > XeTeX: LuaTeX raises lots of issues, I suspect). This includes > \ExplSyntaxOn/Off, \DeclareDocumentCommand and so on. I'd suggest that > these should be \protected. > > I'm not saying it's likely that \edef-ing things like > \DeclareDocumentCommand is likely, but that it seems more consistent. Yes, this is sensible to me. It's (essentially) an extension of how \def itself is \protected. So I would say: any user-level command defined in LaTeX3 that is not expandable should be protected. And any user-defined command (with xparse) is protected, no matter what (I can't think of a case, off the top of my head, where this is undesirable). * * * Moving slightly off-topic, but related to the discussion of protected control sequences: l3basics, in the docs for \cs_set_protected, says to use \exp_after:wN \prg_do_nothing: if you want to expand a protected control sequence in an expanding context. What do you think about the idea of providing a command called \exp_protected:N for doing this? (I.e., good idea or bad idea? Or unnecessary?) Will --Apple-Mail-1-999783362 Content-Disposition: attachment; filename=smime.p7s Content-Type: application/pkcs7-signature; name=smime.p7s Content-Transfer-Encoding: base64 MIAGCSqGSIb3DQEHAqCAMIACAQExCzAJBgUrDgMCGgUAMIAGCSqGSIb3DQEHAQAAoIIGITCCAtow ggJDoAMCAQICECN4qE5kBXLk2f/jVDfSZPwwDQYJKoZIhvcNAQEFBQAwYjELMAkGA1UEBhMCWkEx JTAjBgNVBAoTHFRoYXd0ZSBDb25zdWx0aW5nIChQdHkpIEx0ZC4xLDAqBgNVBAMTI1RoYXd0ZSBQ ZXJzb25hbCBGcmVlbWFpbCBJc3N1aW5nIENBMB4XDTA5MDEyOTA1NDkxNVoXDTEwMDEyOTA1NDkx NVowQjEfMB0GA1UEAxMWVGhhd3RlIEZyZWVtYWlsIE1lbWJlcjEfMB0GCSqGSIb3DQEJARYQd3Nw cjgxQGdtYWlsLmNvbTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAL0BeSiAbKuqxeRN p2qn/m8ZL+xawr/WXyPgEF0FipWgRe9l3sMXcFHokcUu0xOc97R7xkUsGcQ8EyybGHuWey6x7X1Y xJZXnoAxqcaG+eREytoYGMIKs6BhEEogLVb2ERw3lQNVnOzanSFeGo8suMAN4zzCtqAjJiA1ph7h 1pksTgECYK5EiIZbFsB6zSDa8crNk404z1CfIA6YO8ezvjbDda+D0r8NU2tq9WS9F5IaG+bW71Ya JegEcSZ+WF6Z+fs2MUMCLLu8n50Er0nuy4dxOmkdMRNfbeaM39dsEwjAAgcQnvPNmlJ215nZWQRH 49YowtSBOYUYq0ZylWRE6x8CAwEAAaMtMCswGwYDVR0RBBQwEoEQd3NwcjgxQGdtYWlsLmNvbTAM BgNVHRMBAf8EAjAAMA0GCSqGSIb3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