Received: from mx0.gmx.net (mx0.gmx.net [213.165.64.100]) by h1439878.stratoserver.net (8.14.2/8.14.2/Debian-2build1) with SMTP id pB4EIFSo023855 for ; Sun, 4 Dec 2011 15:18:17 +0100 Received: (qmail 1196 invoked by alias); 4 Dec 2011 14:18:10 -0000 Delivered-To: GMX delivery to rainer.schoepf@gmx.net Received: (qmail invoked by alias); 04 Dec 2011 14:18:10 -0000 Received: from relay.uni-heidelberg.de (EHLO relay.uni-heidelberg.de) [129.206.100.212] by mx0.gmx.net (mx086) with SMTP; 04 Dec 2011 15:18:10 +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 pB4EFanW000693 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sun, 4 Dec 2011 15:15:36 +0100 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 pB3N16xa010506; Sun, 4 Dec 2011 15:15:35 +0100 Received: by LISTSERV.UNI-HEIDELBERG.DE (LISTSERV-TCP/IP release 16.0) with spool id 1926852 for LATEX-L@LISTSERV.UNI-HEIDELBERG.DE; Sun, 4 Dec 2011 15:15:35 +0100 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 pB4EFZHW023841 for ; Sun, 4 Dec 2011 15:15:35 +0100 Received: from lon1-msapost-1.mail.demon.net (lon1-msapost-1.mail.demon.net [195.173.77.180]) by relay.uni-heidelberg.de (8.14.1/8.14.1) with ESMTP id pB4EFLiW000639 for ; Sun, 4 Dec 2011 15:15:29 +0100 Received: from morningstar2.demon.co.uk ([80.176.134.7] helo=palladium.local) by lon1-post-1.mail.demon.net with esmtpsa (AUTH morningstar2) (TLSv1:AES256-SHA:256) (Exim 4.69) id 1RXCqf-00007C-XE for LATEX-L@LISTSERV.UNI-HEIDELBERG.DE; Sun, 04 Dec 2011 14:15:21 +0000 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:8.0) Gecko/20111105 Thunderbird/8.0 MIME-Version: 1.0 References: <4ED9ED20.40004@morningstar2.co.uk> <4EDA0732.5060003@latex-project.org> X-Enigmail-Version: 1.3.3 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Message-ID: <4EDB8079.6000707@morningstar2.co.uk> Date: Sun, 4 Dec 2011 14:15:21 +0000 Reply-To: Mailing list for the LaTeX3 project Sender: Mailing list for the LaTeX3 project From: Joseph Wright Subject: Re: Documentation of local/global variants To: LATEX-L@listserv.uni-heidelberg.de In-Reply-To: <4EDA0732.5060003@latex-project.org> Precedence: list List-Help: , List-Unsubscribe: List-Subscribe: List-Owner: List-Archive: X-GMX-Antispam: 0 (Sender is in whitelist: joseph.wright@MORNINGSTAR2.CO.UK); Detail=5D7Q89H36p4L00VTXC6D4q0N+AH0PUCnBi0P5cROEGjO+pG7NAH/K+tf9SrVFtpLrKONl 2T9EL4W4U4jgzLbnCcGpk1z/zwmKT/K1fv3lD0=V1; X-Resent-By: Forwarder X-Resent-For: rainer.schoepf@gmx.net X-Resent-To: rainer@rainer-schoepf.de Status: R X-Status: X-Keywords: X-UID: 6970 On 03/12/2011 11:25, Frank Mittelbach wrote: > Am 03.12.2011 10:34, schrieb Joseph Wright: > >> I wonder if it would make more sense to take the same approach for >> functions with local/global versions. Something like: >> >> 'Where functions for variable manipulation can apply either locally or >> globally, the latter case is indicated by the inclusion of a "g" in the >> last part of the function name. Thus \tl_set:Nn is a local function but >> \tl_gset:Nn acts globally. Functions of this type are always documented >> together, and the scope of action may therefore be inferred from the >> presence or absence of a "g".' >> >> The scope would then be excluded from the function documentation: >> >> % \begin{function} >> % { >> % \tl_set:Nn, \tl_set:cn, >> % \tl_gset:Nn, \tl_gset:cn >> % } >> % \begin{syntax} >> % \cs{tl_set:Nn} \meta{tl~var} \Arg{tokens} >> % \end{syntax} >> % Sets \meta{tl~var} to contain \meta{tokens}, >> % removing any previous content from the variable. >> % \end{function} >> >> Does this make sense as a sensible balance between formality and >> documentation length? > > I would be quite happy with this approach of documenting local and > global variants in a single place together as the convention is in > nearly all cases very clear and the use of "g" or its absence > understandable without further explanation (other than at the very > beginning outlining the approach). And in the few cases where the "g" > may need additional explanation because it could refer to one or the > other argument that could still either be done on the spot or if > necessary in that case split into separate documentation blocks. Hello Frank, Yes, there are a few cases where such a convention would not be sufficient, for example \prop_(g)get:NnN. As I said, this mirrors the situation with TF functions, where there are a few in which the documentation does have to cover more complex situations on a case-by-case basis. -- Joseph Wright