<div dir="ltr">Oh, dang, looks like the TFM file format does not require bc <= ec.<div>The amsfonts/dummy example is loaded by TeX and also accepted</div><div>by tftopl.  It does require however that bc <= ec+1 and that ec<256.</div><div><br></div><div>The tftopl check reads as follows:<br></div><div><pre style="color:rgb(0,0,0);white-space:pre-wrap">if (bc>ec+1)or(ec>255) then abort('The character code range ',</pre><pre style="color:rgb(0,0,0);white-space:pre-wrap"><div style="color:rgb(34,34,34);font-family:Arial,Helvetica,sans-serif;white-space:normal">In TeX we see:</div><div style="color:rgb(34,34,34);font-family:Arial,Helvetica,sans-serif;white-space:normal"><pre style="color:rgb(0,0,0);white-space:pre-wrap">if (bc>ec+1)or(ec>255) then abort;
if bc>255 then {|bc=256| and |ec=255|}
  begin bc:=1; ec:=0;
  end;</pre></div><div style="color:rgb(34,34,34);font-family:Arial,Helvetica,sans-serif;white-space:normal">That second part is interesting and unexpected; I believe it's there just so</div><div style="color:rgb(34,34,34);font-family:Arial,Helvetica,sans-serif;white-space:normal">a tfm file that is empty but using bc=256/ec=255 to indicate that, can still</div><div style="color:rgb(34,34,34);font-family:Arial,Helvetica,sans-serif;white-space:normal">work in an environment where bc and ec are stored in 8-bit bytes.</div><div style="color:rgb(34,34,34);font-family:Arial,Helvetica,sans-serif;white-space:normal"><br></div><div style="color:rgb(34,34,34);font-family:Arial,Helvetica,sans-serif;white-space:normal">TeX also explicitly ignores extra stuff at the end:</div><div style="color:rgb(34,34,34);font-family:Arial,Helvetica,sans-serif;white-space:normal"><pre style="color:rgb(0,0,0);white-space:pre-wrap">@ We check to see that the \.{TFM} file doesn't end prematurely; but
no error message is given for files having more than |lf| words.
</pre></div><div style="color:rgb(34,34,34);font-family:Arial,Helvetica,sans-serif;white-space:normal"><br></div><div style="color:rgb(34,34,34);font-family:Arial,Helvetica,sans-serif;white-space:normal">-tom</div></pre></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Sep 13, 2019 at 9:04 AM Tomas Rokicki <<a href="mailto:rokicki@gmail.com">rokicki@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">I also noticed the tfm files with the wrong length (extra stuff on the end).<br><div>While this is moderately unfortunate it's also not critical since all the</div><div>TFM parsers appear to read the TFM files front to back and just ignore</div><div>the junk.</div><div><br></div><div>I confirm (with my own TFM parser) that there are 2060 "tfm" files in the</div><div>distribution with bc > ec.  They are in the following directories (with counts</div><div>of the "bad" files).  These files may also have other issues (like bad</div><div>header lengths).  My suspicion is nobody has ever (successfully) used</div><div>any of these fonts.  A cursory test appears to show that TeX cannot load</div><div>these fonts either.</div><div><br></div><div>





<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-m_-485819406095484412gmail-Apple-converted-space">  </span>24 /usr/local/texlive/2019/texmf-dist/fonts/tfm/ptex-fonts/standard</span></p>
<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-m_-485819406095484412gmail-Apple-converted-space">  </span>12 /usr/local/texlive/2019/texmf-dist/fonts/tfm/ptex-fonts/nmin-ngoth</span></p>
<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-m_-485819406095484412gmail-Apple-converted-space">   </span>8 /usr/local/texlive/2019/texmf-dist/fonts/tfm/ptex-fonts/jis</span></p>
<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-m_-485819406095484412gmail-Apple-converted-space">   </span>4 /usr/local/texlive/2019/texmf-dist/fonts/tfm/ptex-fonts/dvips</span></p>
<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures">1080 /usr/local/texlive/2019/texmf-dist/fonts/tfm/public/japanese-otf</span></p>
<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-m_-485819406095484412gmail-Apple-converted-space"> </span>522 /usr/local/texlive/2019/texmf-dist/fonts/tfm/public/japanese-otf-uptex</span></p>
<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-m_-485819406095484412gmail-Apple-converted-space">  </span>40 /usr/local/texlive/2019/texmf-dist/fonts/tfm/public/jlreq</span></p>
<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-m_-485819406095484412gmail-Apple-converted-space">   </span>1 /usr/local/texlive/2019/texmf-dist/fonts/tfm/public/amsfonts/dummy</span></p>
<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-m_-485819406095484412gmail-Apple-converted-space">  </span>24 /usr/local/texlive/2019/texmf-dist/fonts/tfm/public/zhmetrics-uptex</span></p>
<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-m_-485819406095484412gmail-Apple-converted-space"> </span>260 /usr/local/texlive/2019/texmf-dist/fonts/tfm/public/pxufont</span></p>
<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-m_-485819406095484412gmail-Apple-converted-space">  </span>12 /usr/local/texlive/2019/texmf-dist/fonts/tfm/public/hfoldsty</span></p>
<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-m_-485819406095484412gmail-Apple-converted-space">  </span>25 /usr/local/texlive/2019/texmf-dist/fonts/tfm/public/morisawa</span></p>
<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-m_-485819406095484412gmail-Apple-converted-space">  </span>40 /usr/local/texlive/2019/texmf-dist/fonts/tfm/uptex-fonts/jis</span></p>
<p class="gmail-m_-485819406095484412gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,0,0)"><span class="gmail-m_-485819406095484412gmail-s1" style="font-variant-ligatures:no-common-ligatures"><span class="gmail-m_-485819406095484412gmail-Apple-converted-space">   </span>8 /usr/local/texlive/2019/texmf-dist/fonts/tfm/uptex-fonts/min</span></p></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Sep 13, 2019 at 4:13 AM Didier Verna <<a href="mailto:didier@didierverna.net" target="_blank">didier@didierverna.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">"Taylor, P" <<a href="mailto:P.Taylor@rhul.ac.uk" target="_blank">P.Taylor@rhul.ac.uk</a>> wrote:<br>
<br>
> What (if anything) does TFtoPL have to say about the files that your<br>
> parser identifies as being non-compliant ? Philip Taylor<br>
<br>
  It agrees with me :-D<br>
<br>
-- <br>
Resistance is futile. You will be jazzimilated.<br>
<br>
Lisp, Jazz, Aïkido: <a href="http://www.didierverna.info" rel="noreferrer" target="_blank">http://www.didierverna.info</a><br>
<br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail-m_-485819406095484412gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>--  <a href="http://cube20.org/" target="_blank">http://cube20.org/</a>  --  <a href="http://golly.sf.net/" target="_blank">http://golly.sf.net/</a>  --</div></div></div></div></div>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>--  <a href="http://cube20.org/" target="_blank">http://cube20.org/</a>  --  <a href="http://golly.sf.net/" target="_blank">http://golly.sf.net/</a>  --</div></div></div></div></div>