TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm reading through tex.web:

@ Next are the ordinary run-of-the-mill command codes.  Codes that are
|min_internal| or more represent internal quantities that might be
expanded by `\.{\\the}'.

@d char_num=16 {character specified numerically ( \.{\\char} )}

... and I would actually like to call this one:

@d remove_item=25 {nullify last item ( \.{\\unpenalty},
  \.{\\unkern}, \.{\\unskip} )}

Is it possible to somehow call these "ordinary" "command codes" from LaTeX - and how might they be "expanded by \the"?

Edit: to clarify: above I see a "command" called remove_item which has some sort of a code of 25. Is it possible to call this command from LaTeX - maybe through \catcode25 (which doesn't work) or something similar (I'm speculating here: say, something like \cmd:remove_item)?

I don't understand the source code of Tex - but the way I read the above, there is an internal command remove_item in TeX, which apparently calls \unpenalty \unkern \unskip. I was hoping there is a way to call this remove_item from Latex...

share|improve this question
I'm not sure I understand the question but perhaps the answer is \unpenalty and \the\lastpenalty – David Carlisle Jun 28 '12 at 20:20
Thanks for the comment, @DavidCarlisle - I tried to clarify through an edit above, please let me know if I should clarify further. Cheers! – sdaau Jun 28 '12 at 20:25
Oh so in that case the answer is simpler "no" :-) – David Carlisle Jun 28 '12 at 20:40
Many thanks for that, @DavidCarlisle - would you mind posting that comment as an answer so I can accept it? – sdaau Jun 28 '12 at 20:49
up vote 4 down vote accepted

In general there is no automatic mapping between internal functions of the web sources and functionality exposed as TeX primitives, so the answer to your question is essentially "no". You can do \the\lastpenalty and \unpenalty but that isn't quite what you were after.

share|improve this answer
Many thanks for confirming that, @DavidCarlisle - given I lack a lot of the TeX background, I have allowed (in this case) the code comments to slightly mislead me; which is why it's great to have an explicit answer to this documented. Cheers! – sdaau Jun 28 '12 at 21:28

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.