On 06/01/2011 17:15, Frank Mittelbach wrote:
> xparse offer a fairly general snytax including variable delimiters and default
> values per argument and more. Perhaps you should *indeed* have a look at it
> one day :-) and it could be easily used on top of 2e if so desired

Also, while it's not implemented at the moment at a documented level, in 
principal you could globally alter the '[ ... ]' convention to some 
other delimiters for optional arguments by changing how the 'o' argument 
spec. is handled

> what is not offered right now is mandatory arguments with arbitrary delimiters
> on the left or right, though one could achieve even those in an emergency
> using "u" argument type twice (I guess)

It's unlikely to come up a lot, but I'd use an argument processor:

\documentclass{article}
\usepackage{xparse}
\ExplSyntaxOn
\NewDocumentCommand \test { > { \StripPrefix } u { stop } } {
   Argument~received:~`#1'
   }
\NewDocumentCommand \StripPrefix { m } { \StripPrefixAux #1 \q_stop }
\cs_new:Npn \StripPrefixAux start #1 \q_stop {
   \tl_set:Nn \ProcessedArgument {#1}
}
\ExplSyntaxOff
\begin{document}
\test start some test text stop outside!
\end{document}
-- 
Joseph Wright