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 just added \usepackage{tikz}, and I got the "No room for new \dimen" error, which I was able to fix (I think) by just including the etex package as suggested at the link.

However, a different part of document is now giving errors. My document uses the program library, and I get this bad character error code in a style file that belongs to it. If I get rid of the tikz and etex libraries (and comment out my tikz figure code), the document compiles fine.

Is there something that can be done about this?

share|improve this question

program uses \chardef to store the current "allocationnumber". This is not compatible with etex. It breaks as soon as more than 256 dimen are allocated:


\advance\@tempcnta by 1}


That's a bug, so make a bug report.

share|improve this answer
I suspected as much. Can you point me to where bug reports for this sort of thing should be reported? I looked at ctan.org/tex-archive/macros/latex/contrib/program but there's no bug tracker there. Should I just email the author of the package? – donatello Dec 8 '10 at 10:37
Yes sent an email. – Ulrike Fischer Dec 8 '10 at 11:00

Since this is a bug (as Ulrike Fischer's answer says), there may be no way to fix this at the moment.

I managed to work around it by using the algorithmic package instead of the program package. This may be far from ideal if you prefer program's style though, but its good enough for me.

share|improve this answer
perhaps try to load program earlier: if it is loaded early enough the allocation number will still be small enough to fit in a \char. [For some reason I can't get \usepackage{program}\usepackage{tikz} to work in that order, but loading etex,tikz,program in that order seems to work. – Bruno Le Floch Jun 25 '11 at 11:08

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.