[tex-live] l3keys2e class options ignored with TL 2015

Denis Bitouzé dbitouze at wanadoo.fr
Sat Jul 4 11:35:56 CEST 2015


Le 30/06/15 à 09h39, Joseph Wright <joseph.wright at morningstar2.co.uk>
a écrit :

> On 29/06/2015 19:54, Denis Bitouzé wrote:
>> Le 29/06/15 à 13h19, Joseph Wright <joseph.wright at morningstar2.co.uk>
>> a écrit :
>> 
>>> I think I see what is going on here and will fix shortly.
>> 
>> Thanks!
>
> I have a fix in hand and checked in to our SVN. I have a few other
> things to look at this week and will then aim to release.

Thanks!

>> BTW, if you see why the LaTeX warning: "Unused global option(s):
>> [key=foo]", please let me know :)
>
> This is due to the LaTeX2e kernel not the expl3 code. You have in your
> example
>
>     \LoadClassWithOptions{article}
>
> This passes all of the class options to article. It then populates the
> unused list based on options it does not know. If you want to avoid
> that use just
>
>     \LoadClass{article}

It doesn't change anything:

--8<---------------cut here---------------start------------->8---
\begin{filecontents*}{myclass.cls}
\RequirePackage{l3keys2e}
\ExplSyntaxOn
\ProvidesExplClass
{myclass}
{2015/06/28}
{0.1}
{
  My~nice~class!
}
\NeedsTeXFormat{LaTeX2e}

\tl_new:N \g_key_tl
\keys_define:nn { myclass }
{
  key .tl_gset:N = \g_key_tl
}
\ProcessKeysOptions { myclass }
\LoadClass { article }
\ExplSyntaxOff
\end{filecontents*}
%
\documentclass[key=foo]{myclass}
\begin{document}
\ExplSyntaxOn
\tl_show:N \g_key_tl
\ExplSyntaxOff
\end{document}
--8<---------------cut here---------------end--------------->8---

leads to the same warning:

  ┌────
  │ LaTeX Warning: Unused global option(s):
  │     [key=foo].
  └────
-- 
Denis



More information about the tex-live mailing list