2016年2月15日

ptexencのソースを眺めていると,24個より多くファイルを開くとどうなるのか気になってくる.というわけでやってみた.

(1)

\input 2.tex
というファイルを数を増やしてとりあえず50個くらい用意し,\input 1.tex \byeとだけしたsample.texを用意してeptex sample.tex.まずはW32TeXから.

>eptex sample.tex
This is e-pTeX, Version 3.14159265-p3.7-160201-2.6 (sjis) (TeX Live 2016/W32TeX/dev) (preloaded format=eptex)
 restricted \write18 enabled.
entering extended mode
(./sample.tex (./1.tex (./2.tex (./3.tex (./4.tex (./5.tex (./6.tex (./7.tex
(./8.tex (./9.tex (./10.tex (./11.tex (./12.tex (./13.tex (./14.tex
! TeX capacity exceeded, sorry [text input levels=15].
l.3 \input 15.tex

No pages of output.
Transcript written on sample.log.

Oh...TeXの読み込み可能ファイル数はkpathseaの変数max_in_openで制御できる.

set max_in_open=99
とでもして再度挑戦.

>eptex sample.tex
This is e-pTeX, Version 3.14159265-p3.7-160201-2.6 (sjis) (TeX Live 2016/W32TeX/dev) (preloaded format=eptex)
 restricted \write18 enabled.
entering extended mode
(./sample.tex (./1.tex (./2.tex (./3.tex (./4.tex (./5.tex (./6.tex (./7.tex
(./8.tex (./9.tex (./10.tex (./11.tex (./12.tex (./13.tex (./14.tex (./15.tex
(./16.tex (./17.tex (./18.tex (./19.tex (./20.tex

固まった…….Ctrl + Cでも止まらず,タスクマネージャーからkillして止めた.次にTeX LiveのソースからMinGWでビルドしたeptexの場合.

>eptex sample.tex
This is e-pTeX, Version 3.14159265-p3.7-150805-2.6 (sjis) (TeX Live 2016/dev) (preloaded format=eptex)
 restricted \write18 enabled.
entering extended mode
(./sample.tex (./1.tex (./2.tex (./3.tex (./4.tex (./5.tex (./6.tex (./7.tex
(./8.tex (./9.tex (./10.tex (./11.tex (./12.tex (./13.tex (./14.tex (./15.tex
(./16.tex (./17.tex (./18.tex (./19.tex (./20.tex (./21.tex (./22.tex (./23.tex
(./24.tex (./25.tex (./26.tex (./27.tex (./28.tex (./29.tex (./30.tex (./31.tex
(./32.tex (./33.tex (./34.tex (./35.tex (./36.tex (./37.tex (./38.tex (./39.tex
(./40.tex (./41.tex (./42.tex (./43.tex (./44.tex (./45.tex (./46.tex (./47.tex
(./48.tex (./49.tex (./50.tex))))))))))))))))))))))))))))))))))))))))))))))))))
[1] )
Output written on sample.dvi (1 page, 756 bytes).
Transcript written on sample.log.

今度はコンパイルが成功した.出力されたファイルをみてみると(20)の前と最後にΛがふたつ並んでいる.バッファオーバーランでも起こしたのだろうか.

ちなみにpdftexは正常である.

>pdftex sample.tex
This is pdfTeX, Version 3.14159265-2.6-1.40.16 (TeX Live 2016/W32TeX/dev) (preloaded format=pdftex)
 restricted \write18 enabled.
entering extended mode
(./sample.tex (./1.tex (./2.tex (./3.tex (./4.tex (./5.tex (./6.tex (./7.tex
(./8.tex (./9.tex (./10.tex (./11.tex (./12.tex (./13.tex (./14.tex (./15.tex
(./16.tex (./17.tex (./18.tex (./19.tex (./20.tex (./21.tex (./22.tex (./23.tex
(./24.tex (./25.tex (./26.tex (./27.tex (./28.tex (./29.tex (./30.tex (./31.tex
(./32.tex (./33.tex (./34.tex (./35.tex (./36.tex (./37.tex (./38.tex (./39.tex
(./40.tex (./41.tex (./42.tex (./43.tex (./44.tex (./45.tex (./46.tex (./47.tex
(./48.tex (./49.tex (./50.tex))))))))))))))))))))))))))))))))))))))))))))))))))
[1{c:/w32tex/share/texmf-dist/fonts/map/pdftex/updmap/pdftex.map}] )
Output written on sample.pdf (1 page, 11222 bytes).
Transcript written on sample.log.

出力ファイルも想定通り.

0 件のコメント:

コメントを投稿

コメントの追加にはサードパーティーCookieの許可が必要です