[NTG-pdftex] \ifprimitive and \ifinternal/\iffeature (design proposal)

Heiko Oberdiek oberdiek at uni-freiburg.de
Mon Jul 4 16:19:18 CEST 2005


Hello Taco,

On Mon, Jul 04, 2005 at 04:06:42PM +0200, Taco Hoekwater wrote:

> Heiko Oberdiek wrote:
> >
> >What is the result of \ifprimitive, it is \iftrue/\iffalse or
> >an expansion text "true"/"some error message"?
> 
> as in \iftrue/\iffalse: it is a 'real' \if test .
> 
> >> \executeprimitive <csname>
> >
> >What about \executeprimitive itself?
> >
> >  \def\executeprimitive{Hello World}
> >  \executeprimitive\executeprimitive\relax
> >
> >Is the result two "Hello World" or "\relax"?
> 
> This result is
> 
>   Hello WorldHello World\relax
> 
> Without the \def line, you would get only:
> 
>   \relax
> 
> (the first \executeprimitive executes the second which executes
> the internal version of \relax)

Thanks for clarification, this is what I would expect.

> >> \ifinternal <csname>
> >> \executeinternal <csname>
> >> \exposeinternal <csname>
> >> \obscureinternal <csname>
> >
> >It needs some thinking.
> >First thoughts:
> >* It looks like a first step to a real namespace implementation,
> >  a (perhaps read-only) internal namespace, namespaces for extensions,
> >  and user/package macros. Why not going further then?
> 
> TeX's current internal structure does not allow a clean solution,
> so if we want true namespaces in TeX, we probably have to start
> thinking about a successor to pdftex. Otherwise, we would need
> to redesign the whole symbol table / token handling while trying
> to remain 100% compatible. That sounds like a nightmare to me.
> 
> These last 4 primitives I proposed are an attempt to come up with
> something that works next month (as opposed to next year), but
> you are right that it probably needs more thinking, anyway.

I know, the web-pascal code is a nightmare and that we depend
stronger on what can be done than what would be a nice solution.
:-((

Yours sincerely
  Heiko <oberdiek at uni-freiburg.de>


More information about the ntg-pdftex mailing list