Menu

#19 Change of package/<name>/after and class/<name>/after in LaTeX 2021/11/15

LaTeX 2021-11-15
closed
2021-11-09
2021-11-05
Markus Kohm
No

With LaTeX 2021/11/15 the file hooks become one time hooks. So if hook code is added after loading the class or package, they code is executed immediately. Because \AfterPackage and \AfterClass use file/<name>/after the change does not influence these commands, but \AfterEndOfClass and \AfterEndOfPackage, because these use class/<name>/after and package/<name>/after hooks.

The new scrlfile package hook test therefore fails with following difference:

*** ./build/test-build-dev.lua/scrlfile-packages.tlg    2021-11-08 09:15:07.996445424 +0100
--- ./build/test-build-dev.lua/scrlfile-packages.pdftex.log     2021-11-08 09:15:08.560445305 +0100
***************
*** 88,94 ****
  ============================================================
  TEST 18: Test Hook Executed: \AfterAtEndOfPackage{ifthen}
  ============================================================
! Result: FALSE
  ============================================================
  ============================================================
  TEST 19: Test Hook Execute (immediate): \AfterAtEndOfPackage*{ifthen} 
--- 88,94 ----
  ============================================================
  TEST 18: Test Hook Executed: \AfterAtEndOfPackage{ifthen}
  ============================================================
! Result: TRUE
  ============================================================
  ============================================================
  TEST 19: Test Hook Execute (immediate): \AfterAtEndOfPackage*{ifthen} 

So in scrlfile-hook.sty the logic for testing, if a package has already been loaded, has to be copied/moved to the FALSE case of \IfBooleanTF in \AfterAtEndOfClass and \AfterAtEndOfPackage.

No changes needed for scrlfile-patcholdlatex.sty and scrlfile-hook-3.34.sty.

Related

Commit: [r3632]

Discussion

  • Markus Kohm

    Markus Kohm - 2021-11-09
    • status: open --> closed
     
  • Markus Kohm

    Markus Kohm - 2021-11-09

    Fixed in [r3635].

     
    👍
    1

    Related

    Commit: [r3635]


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.