On Wed, 11 Jul 2007, Wolfgang Schuster wrote:
2007/7/10, Aditya Mahajan
: Hi Wolfgang,
Quoting Wolfgang Schuster
: Hi Aditya,
the macro eats the endline char.
That would mean that tex will parse ============= \section why \unknown
test
=============
as
=============== \section why \unknown test
================
but it does not. What I dislike is the fact that TeX gives an error message.
Aditya
Hi Aditya,
the problem lies in the definition of \dowithpargument. The current defintion is:
\def\dowithpargument#1% {\def\nextpar##1 \par{#1{##1}}% \def\nextarg##1{#1{##1}}% \doifnextcharelse\bgroup\nextarg{\doifnextcharelse\par{#1{}}\nextpar}}
The problem is the space after ##1 in the \nexpar defintion, it should be:
\def\dowithpargument#1% {\def\nextpar##1\par{#1{##1}}% \def\nextarg##1{#1{##1}}% \doifnextcharelse\bgroup\nextarg{\doifnextcharelse\par{#1{}}\nextpar}}
and everything works fine.
Ah, thanks. Aditya