Content-Type: |
TEXT/PLAIN; charset=US-ASCII; format=flowed |
Sender: |
|
Subject: |
|
From: |
|
Date: |
Mon, 14 Nov 2005 20:11:34 +0100 |
In-Reply-To: |
|
MIME-Version: |
1.0 |
Reply-To: |
|
Parts/Attachments: |
|
|
On Mon, 14 Nov 2005, Joachim Schrod wrote:
>>>>>> "WR" == Will Robertson <[log in to unmask]> writes:
>
> WR> The token stream won't change retrospectively, so in theory it
> WR> should be able to be examined.
>
> But it does change. That's the whole point of macros, to change the
> token stream.
>
> With a definition of
>
> \newcommand\a[1]{f1\b{#1}}
> \newcommand\b[2]{\par #2 #1}
those two probably ought to be \renewcommand instead of \newcommand
>
> and an input of
>
> ab\a12
>
> this results in the following token stream [*]
Although irrelevant for the conclusion, you (JS) should have gotten this
right:
>
> (char "a") (char "b") (cseq "a") (other "1") (other "2")
>
> which is in turn transformed into the token stream
>
> (char "a") (char "b") (cseq "b") (bgroup "{") (other "1")
> (egroup "}") (other "2")
should read
(char "a") (char "b") (char "f") (other "1") (cseq "b")
(bgroup "{") (other "1") (egroup "}") (other "2")
>
> and then into the token stream
>
> (char "a") (char "b") (cseq "par") (other "2") (other "1")
should read
(char "a") (char "b") (char "f") (other "1") (cseq "par")
(other "2") (space " ") (other "1")
>
> Which of those do you want to keep? There are good arguments for all
> of them.
> ........
Peter Breitenlohner <[log in to unmask]>
|
|
|