LATEX-L Archives

Mailing list for the LaTeX3 project

LATEX-L@LISTSERV.UNI-HEIDELBERG.DE

Options: Use Forum View

Use Monospaced Font
Show Text Part by Default
Condense Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Sender:
Mailing list for the LaTeX3 project <[log in to unmask]>
Date:
Sun, 23 Aug 2009 13:44:13 +0100
Reply-To:
Mailing list for the LaTeX3 project <[log in to unmask]>
Subject:
MIME-Version:
1.0
Content-Transfer-Encoding:
7bit
In-Reply-To:
Content-Type:
text/plain; charset=ISO-8859-1
From:
Joseph Wright <[log in to unmask]>
Parts/Attachments:
text/plain (56 lines)
Frank Mittelbach wrote:

> sorry not very clear I agree. This remark was largely due to a
> misunderstanding on my part from reading the current documentation For example
> 
>    \foo {[}bar]{baz}
> 
> shouldn't be interpreted as \foo[bar]{baz} (which it isn't, except in a
> special extension).

I do hope that the reasoning for including
\DeclareExpandableDocumentCommand is okay. It seemed like a better way
to cover the special cases than the current ad hoc situation.

>  > As you probably realise, my overall feeling is that for many (most?) end
>  > users, a LaTeX2e-like syntax will remain the best way to use LaTeX
>  > whatever we deliver as LaTeX3. 
> 
> agreed, but that doesn't mean that it (the final standard syntax) is equal to 2e syntax

I did say "LaTeX3e-like", meaning something that probably involves TeX
escaped keywords and so on. I'd not expect nothing to change.

> On the other hand I would probably prefer the current state to be called
> xparse-2e and run with that as stable. Then Bill, for example, could easily
> build a matching xparse-gellmu and promote using this document level syntax
> for accessing the other latex3 layers, etc. And we can leave the name xparse
> for a more "final" interface version.

How do you see that working with things like \DeclareDocumentCommand.
Two options come to mind:

1) Given them names which reflect the separation
(\DeclareLaTeXDocumentCommand, etc.)

2) Add an extra "model" argument:

\DeclareDocumentCommand { <model> } { <name> } { <argument-detail> }
  { <code> }

where we make no assumptions about anything here and do something like

\cs_set_protected:Npn \DeclareDocumentCommand #1#2#3#4 {
  \cs_if_exist:cTF { xparse_declare_cmd_ #1 :nnn } {
    \use:c { xparse_ #1 _declare_cmd:nnn } {#2} {#3} {#4}
  }{
    \msg_error:nnx { xparse } { unknown-model } {#1}
  }
}

This would assume dividing the current code in half: one truly generic
part to just provide things like \DeclareDocumentCommand, and one
containing the xparse-2e idea.
-- 
Joseph Wright

ATOM RSS1 RSS2