diff options
author | Karl Berry <karl@freefriends.org> | 2019-10-11 21:33:04 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2019-10-11 21:33:04 +0000 |
commit | 83b507f56f72909f7552936d229f1130c8fb05c5 (patch) | |
tree | 360f905351d9db1e1be9168840b76d7ba8c1e4ca /Master/texmf-dist/tex/latex/l3kernel | |
parent | aa2dbb8897371a36028d3ce667140365345dfbfe (diff) |
l3 (11oct19)
git-svn-id: svn://tug.org/texlive/trunk@52343 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/l3kernel')
-rw-r--r-- | Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex | 388 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex | 5 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/l3kernel/expl3.ltx | 139 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/l3kernel/expl3.lua | 8 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/l3kernel/expl3.sty | 54 |
5 files changed, 419 insertions, 175 deletions
diff --git a/Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex b/Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex index 672739004e7..8d8b7973ea9 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex +++ b/Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex @@ -65,7 +65,7 @@ %% and all files in that bundle must be distributed together. %% %% File: expl3.dtx -\def\ExplFileDate{2019-10-02}% +\def\ExplFileDate{2019-10-11}% \begingroup \def\next{\endgroup}% \expandafter\ifx\csname PackageError\endcsname\relax @@ -147,18 +147,12 @@ \begingroup\expandafter\expandafter\expandafter\endgroup \expandafter\ifx\csname directlua\endcsname\relax \else - \ifnum\luatexversion<70 % + \ifnum\luatexversion<95 % \else \begingroup\expandafter\expandafter\expandafter\endgroup \expandafter\ifx\csname newcatcodetable\endcsname\relax \input{ltluatex}% \fi - \newcatcodetable\ucharcat@table - \directlua{ - l3kernel = l3kernel or { } - local charcat_table = \number\ucharcat@table\space - l3kernel.charcat_table = charcat_table - }% \directlua{require("expl3")}% \ifnum 0% \directlua{ @@ -184,7 +178,7 @@ These are available in the engines\LineBreak - pdfTeX v1.40\LineBreak - XeTeX v0.99992\LineBreak - - LuaTeX v0.76\LineBreak + - LuaTeX v0.95\LineBreak - e-(u)pTeX mid-2012\LineBreak or later.\LineBreak \LineBreak @@ -3876,6 +3870,7 @@ \__cs_tmp:w { Vo } \__cs_tmp:w { fo } \__cs_tmp:w { ff } +\__cs_tmp:w { ee } \__cs_tmp:w { Nx } \__cs_tmp:w { cx } \__cs_tmp:w { nx } @@ -7442,7 +7437,6 @@ { \if_int_compare:w `{ = \c_zero_int } \fi: } \int_new:N \g__kernel_prg_map_int %% File: l3sys.dtx -\str_const:Nx \c_sys_jobname_str { \tex_jobname:D } \cs_new_protected:Npn \__sys_const:nn #1#2 { \bool_if:nTF {#2} @@ -7478,82 +7472,72 @@ \__sys_const:nn { sys_if_engine_ #1 } { \str_if_eq_p:Vn \c_sys_engine_str {#1} } } -\group_begin: - \cs_set:Npn \__sys_tmp:w #1 - { - \str_if_eq:eeTF { \cs_meaning:N #1 } { \token_to_str:N #1 } - { #1 } - { - \cs_if_exist:NTF \tex_primitive:D - { - \bool_lazy_and:nnTF - { \sys_if_engine_xetex_p: } - { - \int_compare_p:nNn - { \exp_after:wN \use_none:n \tex_XeTeXrevision:D } - < { 99999 } - } - { 0 } - { \tex_primitive:D #1 } - } - { 0 } - } - } - \int_const:Nn \c_sys_minute_int - { \int_mod:nn { \__sys_tmp:w \time } { 60 } } - \int_const:Nn \c_sys_hour_int - { \int_div_truncate:nn { \__sys_tmp:w \time } { 60 } } - \int_const:Nn \c_sys_day_int { \__sys_tmp:w \day } - \int_const:Nn \c_sys_month_int { \__sys_tmp:w \month } - \int_const:Nn \c_sys_year_int { \__sys_tmp:w \year } -\group_end: -\str_const:Nx \c_sys_output_str - { - \int_compare:nNnTF - { \cs_if_exist_use:NF \tex_pdfoutput:D { 0 } } > { 0 } - { pdf } - { dvi } - } -\__sys_const:nn { sys_if_output_dvi } - { \str_if_eq_p:Vn \c_sys_output_str { dvi } } -\__sys_const:nn { sys_if_output_pdf } - { \str_if_eq_p:Vn \c_sys_output_str { pdf } } \__sys_const:nn { sys_if_rand_exist } { \cs_if_exist_p:N \tex_uniformdeviate:D } -\sys_if_rand_exist:TF - { \cs_new:Npn \sys_rand_seed: { \tex_the:D \tex_randomseed:D } } - { - \cs_new:Npn \sys_rand_seed: - { - \int_value:w - \__kernel_msg_expandable_error:nnn { kernel } { fp-no-random } - { \sys_rand_seed: } - \c_zero_int - } - } -\sys_if_rand_exist:TF - { - \cs_new_protected:Npn \sys_gset_rand_seed:n #1 - { \tex_setrandomseed:D \int_eval:n {#1} \exp_stop_f: } - } +\cs_new_protected:Npn \sys_load_backend:n #1 { - \cs_new_protected:Npn \sys_gset_rand_seed:n #1 + \sys_finalise: + \str_if_exist:NTF \c_sys_backend_str + { \__kernel_msg_error:nn { sys } { backend-set } } { - \__kernel_msg_error:nnn { kernel } { fp-no-random } - { \sys_gset_rand_seed:n {#1} } + \tl_if_blank:nF {#1} + { \tl_set:Nn \g__sys_backend_tl {#1} } + \__sys_load_backend_check:N \g__sys_backend_tl + \str_const:Nx \c_sys_backend_str { \g__sys_backend_tl } + \__kernel_sys_configuration_load:n + { l3backend- \c_sys_backend_str } } } -\int_const:Nn \c_sys_shell_escape_int +\cs_new_protected:Npn \__sys_load_backend_check:N #1 { - \sys_if_engine_luatex:TF + \sys_if_engine_xetex:TF { - \tex_directlua:D - { tex.sprint(status.shell_escape~or~os.execute()) } + \str_if_eq:VnF #1 { xdvipdfmx } + { + \__kernel_msg_error:nnxx { sys } { wrong-backend } + #1 { xdvipdfmx } + \tl_gset:Nn #1 { xdvipdfmx } + } } { - \tex_shellescape:D + \sys_if_output_pdf:TF + { + \str_if_eq:VnF #1 { pdfmode } + { + \__kernel_msg_error:nnxx { sys } { wrong-backend } + #1 { pdfmode } + \tl_gset:Nn #1 { pdfmode } + } + } + { + \str_case:VnF #1 + { + { dvipdfmx } { } + { dvips } { } + { dvisvgm } { } + } + { + \__kernel_msg_error:nnxx { sys } { wrong-backend } + #1 { dvips } + \tl_gset:Nn #1 { dvips } + } + } } } +\bool_new:N \g__sys_debug_bool +\bool_new:N \g__sys_deprecation_bool +\cs_new_protected:Npn \sys_load_debug: + { + \bool_if:NF \g__sys_debug_bool + { \__kernel_sys_configuration_load:n { l3debug } } + \bool_gset_true:N \g__sys_debug_bool + } +\cs_new_protected:Npn \sys_load_deprecation: + { + \bool_if:NF \g__sys_deprecation_bool + { \__kernel_sys_configuration_load:n { l3deprecation } } + \bool_gset_true:N \g__sys_deprecation_bool + } \tl_new:N \l__sys_internal_tl \tl_const:Nx \c__sys_marker_tl { : \token_to_str:N : } \cs_new_protected:Npn \sys_get_shell:nnN #1#2#3 @@ -7596,12 +7580,6 @@ \group_end: \tl_set:No #1 {#2} } -\__sys_const:nn { sys_if_shell } - { \int_compare_p:nNn \c_sys_shell_escape_int > 0 } -\__sys_const:nn { sys_if_shell_unrestricted } - { \int_compare_p:nNn \c_sys_shell_escape_int = 1 } -\__sys_const:nn { sys_if_shell_restricted } - { \int_compare_p:nNn \c_sys_shell_escape_int = 2 } \sys_if_engine_luatex:F { \int_const:Nn \c__sys_shell_stream_int { 18 } } \sys_if_engine_luatex:TF @@ -7630,85 +7608,162 @@ { \iow_shipout:Nn \c__sys_shell_stream_int {#1} } } \cs_generate_variant:Nn \sys_shell_shipout:n { x } -\tl_new:N \g__sys_backend_tl -\tl_gset:Nx \g__sys_backend_tl +\cs_new_protected:Npn \sys_everyjob: { - \sys_if_engine_xetex:TF - { xdvipdfmx } - { - \sys_if_output_pdf:TF - { pdfmode } - { - \bool_lazy_or:nnTF - { \sys_if_engine_ptex_p: } - { \sys_if_engine_uptex_p: } - { dvipdfmx } - { dvips } - } - } + \tl_use:N \g__sys_everyjob_tl + \tl_gclear:N \g__sys_everyjob_tl } -\cs_new_protected:Npn \sys_load_backend:n #1 +\cs_new_protected:Npn \__sys_everyjob:n #1 + { \tl_gput_right:Nn \g__sys_everyjob_tl {#1} } +\tl_new:N \g__sys_everyjob_tl +\__sys_everyjob:n + { \str_const:Nx \c_sys_jobname_str { \tex_jobname:D } } +\__sys_everyjob:n { - \str_if_exist:NTF \c_sys_backend_str - { \__kernel_msg_error:nnxx { sys } { backend-set } } + \group_begin: + \cs_set:Npn \__sys_tmp:w #1 + { + \str_if_eq:eeTF { \cs_meaning:N #1 } { \token_to_str:N #1 } + { #1 } + { + \cs_if_exist:NTF \tex_primitive:D + { + \bool_lazy_and:nnTF + { \sys_if_engine_xetex_p: } + { + \int_compare_p:nNn + { \exp_after:wN \use_none:n \tex_XeTeXrevision:D } + < { 99999 } + } + { 0 } + { \tex_primitive:D #1 } + } + { 0 } + } + } + \int_const:Nn \c_sys_minute_int + { \int_mod:nn { \__sys_tmp:w \time } { 60 } } + \int_const:Nn \c_sys_hour_int + { \int_div_truncate:nn { \__sys_tmp:w \time } { 60 } } + \int_const:Nn \c_sys_day_int { \__sys_tmp:w \day } + \int_const:Nn \c_sys_month_int { \__sys_tmp:w \month } + \int_const:Nn \c_sys_year_int { \__sys_tmp:w \year } + \group_end: + } +\__sys_everyjob:n + { + \sys_if_rand_exist:TF + { \cs_new:Npn \sys_rand_seed: { \tex_the:D \tex_randomseed:D } } { - \tl_if_blank:nF {#1} - { \tl_set:Nn \g__sys_backend_tl {#1} } - \__sys_load_backend_check:N \g__sys_backend_tl - \str_const:Nx \c_sys_backend_str { \g__sys_backend_tl } - \__kernel_sys_configuration_load:n - { l3backend- \c_sys_backend_str } + \cs_new:Npn \sys_rand_seed: + { + \int_value:w + \__kernel_msg_expandable_error:nnn { kernel } { fp-no-random } + { \sys_rand_seed: } + \c_zero_int + } } } -\cs_new_protected:Npn \__sys_load_backend_check:N #1 +\__sys_everyjob:n { - \sys_if_engine_xetex:TF + \sys_if_rand_exist:TF { - \str_if_eq:VnF #1 { xdvipdfmx } + \cs_new_protected:Npn \sys_gset_rand_seed:n #1 + { \tex_setrandomseed:D \int_eval:n {#1} \exp_stop_f: } + } + { + \cs_new_protected:Npn \sys_gset_rand_seed:n #1 { - \__kernel_msg_error:nnxx { sys } { wrong-backend } - #1 { xdvipdfmx } - \tl_gset:Nn #1 { xdvipdfmx } + \__kernel_msg_error:nnn { kernel } { fp-no-random } + { \sys_gset_rand_seed:n {#1} } } } + } +\__sys_everyjob:n + { + \int_const:Nn \c_sys_shell_escape_int { - \sys_if_output_pdf:TF + \sys_if_engine_luatex:TF { - \str_if_eq:VnF #1 { pdfmode } - { - \__kernel_msg_error:nnxx { sys } { wrong-backend } - #1 { pdfmode } - \tl_gset:Nn #1 { pdfmode } - } + \tex_directlua:D + { tex.sprint(status.shell_escape~or~os.execute()) } } + { \tex_shellescape:D } + } + } +\__sys_everyjob:n + { + \__sys_const:nn { sys_if_shell } + { \int_compare_p:nNn \c_sys_shell_escape_int > 0 } + \__sys_const:nn { sys_if_shell_unrestricted } + { \int_compare_p:nNn \c_sys_shell_escape_int = 1 } + \__sys_const:nn { sys_if_shell_restricted } + { \int_compare_p:nNn \c_sys_shell_escape_int = 2 } + } +\__sys_everyjob:n + { \str_gset:Nx \g_file_curr_name_str { \tex_jobname:D } } +\cs_new_protected:Npn \sys_finalise: + { + \sys_everyjob: + \tl_use:N \g__sys_finalise_tl + \tl_gclear:N \g__sys_finalise_tl + } +\cs_new_protected:Npn \__sys_finalise:n #1 + { \tl_gput_right:Nn \g__sys_finalise_tl {#1} } +\tl_new:N \g__sys_finalise_tl +\__sys_finalise:n + { + \str_const:Nx \c_sys_output_str + { + \int_compare:nNnTF + { \cs_if_exist_use:NF \tex_pdfoutput:D { 0 } } > { 0 } + { pdf } + { dvi } + } + \__sys_const:nn { sys_if_output_dvi } + { \str_if_eq_p:Vn \c_sys_output_str { dvi } } + \__sys_const:nn { sys_if_output_pdf } + { \str_if_eq_p:Vn \c_sys_output_str { pdf } } + } +\__sys_finalise:n + { + \cs_if_exist:NT \@classoptionslist + { + \cs_if_eq:NNF \@classoptionslist \scan_stop: { - \str_case:VnF #1 + \clist_map_inline:Nn \@classoptionslist { - { dvipdfmx } { } - { dvips } { } - { dvisvgm } { } - } - { - \__kernel_msg_error:nnxx { sys } { wrong-backend } - #1 { dvips } - \tl_gset:Nn #1 { dvips } + \str_case:nnT {#1} + { + { dvipdfmx } + { \tl_gset:Nn \g__sys_backend_tl { dvipdfmx } } + { dvips } + { \tl_gset:Nn \g__sys_backend_tl { dvips } } + { dvisvgm } + { \tl_gset:Nn \g__sys_backend_tl { dvisvgm } } + { pdftex } + { \tl_gset:Nn \g__sys_backend_tl { pdfmode } } + { xetex } + { \tl_gset:Nn \g__sys_backend_tl { xdvipdfmx } } + } + { \clist_remove_all:Nn \@unusedoptionlist {#1} } } } } } -\bool_new:N \g__sys_debug_bool -\bool_new:N \g__sys_deprecation_bool -\cs_new_protected:Npn \sys_load_debug: - { - \bool_if:NF \g__sys_debug_bool - { \__kernel_sys_configuration_load:n { l3debug } } - \bool_gset_true:N \g__sys_debug_bool - } -\cs_new_protected:Npn \sys_load_deprecation: +\tl_new:N \g__sys_backend_tl +\__sys_finalise:n { - \bool_if:NF \g__sys_deprecation_bool - { \__kernel_sys_configuration_load:n { l3deprecation } } - \bool_gset_true:N \g__sys_deprecation_bool + \tl_gset:Nx \g__sys_backend_tl + { + \sys_if_engine_xetex:TF + { xdvipdfmx } + { + \sys_if_output_pdf:TF + { pdfmode } + { dvips } + } + } } %% File: l3clist.dtx \cs_new_eq:NN \c_empty_clist \c_empty_tl @@ -10307,11 +10362,14 @@ } } \cs_generate_variant:Nn \__kernel_ior_open:Nn { No } -\cs_new_protected:Npn \__ior_open_stream:Nn #1#2 +\cs_new_protected:Npx \__ior_open_stream:Nn #1#2 { - \tex_global:D \tex_chardef:D #1 = \l__ior_stream_tl \scan_stop: - \prop_gput:NVn \g__ior_streams_prop #1 {#2} - \tex_openin:D #1 #2 \scan_stop: + \tex_global:D \tex_chardef:D #1 = \exp_not:N \l__ior_stream_tl \scan_stop: + \prop_gput:NVn \exp_not:N \g__ior_streams_prop #1 {#2} + \tex_openin:D #1 + \sys_if_engine_luatex:TF + { {#2} } + { #2 \scan_stop: } } \cs_new_protected:Npn \ior_close:N #1 { @@ -10890,8 +10948,6 @@ \str_new:N \g_file_curr_dir_str \str_new:N \g_file_curr_ext_str \str_new:N \g_file_curr_name_str -\cs_if_exist:NT \@currname - { \str_gset_eq:NN \g_file_curr_name_str \@currname } \seq_new:N \g__file_stack_seq \group_begin: \cs_set_protected:Npn \__file_tmp:w #1#2#3 @@ -10912,7 +10968,10 @@ } } \cs_if_exist:NT \@currnamestack - { \exp_after:wN \__file_tmp:w \@currnamestack } + { + \tl_if_empty:NF \@currnamestack + { \exp_after:wN \__file_tmp:w \@currnamestack } + } \group_end: \seq_new:N \g__file_record_seq \tl_new:N \l__file_base_name_tl @@ -11108,9 +11167,27 @@ \cs_new:Npx \__file_file_ext_check_auxiii:nw #1#2 . #3 . #4 \q_stop { \exp_not:N \quark_if_nil:nTF {#3} - { \exp_not:N \__kernel_file_name_quote:n { #1 \tl_to_str:n { .tex } } } + { + \exp_not:N \exp_args:Nee \exp_not:N \__file_file_ext_check_auxiv:nn + { \exp_not:N \__kernel_file_name_quote:n {#1} } + { + \exp_not:N \__kernel_file_name_quote:n + { #1 \tl_to_str:n { .tex } } + } + } {#1} } +\cs_new:Npn \__file_file_ext_check_auxiv:nn #1#2 + { + \tl_if_blank:eTF { \__file_file_size:n {#2} } + {#1} + { + \int_compare:nNnTF + { \__file_file_size:n {#1} } = { \__file_file_size:n {#2} } + {#2} + {#1} + } + } \bool_lazy_or:nnF { \cs_if_exist_p:N \tex_filesize:D } { \sys_if_engine_luatex_p: } @@ -11470,14 +11547,17 @@ { } { } { } } \cs_new:Npn \__file_list_aux:n #1 { \iow_newline: #1 } -\AtBeginDocument - { - \exp_args:NNx \seq_set_from_clist:Nn \l__file_tmp_seq - { \tl_to_str:N \@filelist } - \seq_gconcat:NNN - \g__file_record_seq - \g__file_record_seq - \l__file_tmp_seq +\cs_if_exist:NT \@filelist + { + \AtBeginDocument + { + \exp_args:NNx \seq_set_from_clist:Nn \l__file_tmp_seq + { \tl_to_str:N \@filelist } + \seq_gconcat:NNN + \g__file_record_seq + \g__file_record_seq + \l__file_tmp_seq + } } \cs_new_protected:Npn \GetIdInfo { diff --git a/Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex b/Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex index 61161e0b5fe..b57d838d549 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex +++ b/Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex @@ -19,7 +19,7 @@ %% and all files in that bundle must be distributed together. %% %% File: expl3.dtx -\def\ExplFileDate{2019-10-02}% +\def\ExplFileDate{2019-10-11}% \let\ExplLoaderFileDate\ExplFileDate \begingroup \def\tempa{LaTeX2e}% @@ -58,7 +58,7 @@ }% \catcode64=11 % \let\expl@AtBeginDocument\AtBeginDocument -\def\AtBeginDocument#1{}% +\def\AtBeginDocument#1{#1}% \expandafter\def\expandafter\l@expl@tidy@tl\expandafter {% \l@expl@tidy@tl @@ -85,6 +85,7 @@ } \tex_input:D #1 .def \scan_stop: } +\sys_everyjob: \sys_load_backend:n { } \ExplSyntaxOff \l@expl@tidy@tl diff --git a/Master/texmf-dist/tex/latex/l3kernel/expl3.ltx b/Master/texmf-dist/tex/latex/l3kernel/expl3.ltx new file mode 100644 index 00000000000..44264b3a188 --- /dev/null +++ b/Master/texmf-dist/tex/latex/l3kernel/expl3.ltx @@ -0,0 +1,139 @@ +%% +%% This is file `expl3.ltx', +%% generated with the docstrip utility. +%% +%% The original source files were: +%% +%% expl3.dtx (with options: `2ekernel,loader') +%% +%% Copyright (C) 1990-2019 The LaTeX3 Project +%% +%% It may be distributed and/or modified under the conditions of +%% the LaTeX Project Public License (LPPL), either version 1.3c of +%% this license or (at your option) any later version. The latest +%% version of this license is in the file: +%% +%% https://www.latex-project.org/lppl.txt +%% +%% This file is part of the "l3kernel bundle" (The Work in LPPL) +%% and all files in that bundle must be distributed together. +%% +%% File: expl3.dtx +\def\ExplFileDate{2019-10-11}% +\let\ExplLoaderFileDate\ExplFileDate +\everyjob\expandafter{\the\everyjob + \message{^^J\ExplFileDate\space L3 programming layer}% +} +\protected\def\ProvidesExplPackage#1#2#3#4% + {% + \ProvidesPackage{#1}[#2 \ifx\relax#3\relax\else v#3\space\fi #4]% + \ExplSyntaxOn + }% +\protected\def\ProvidesExplClass#1#2#3#4% + {% + \ProvidesClass{#1}[#2 \ifx\relax#3\relax\else v#3\space\fi #4]% + \ExplSyntaxOn + }% +\protected\def\ProvidesExplFile#1#2#3#4% + {% + \ProvidesFile{#1}[#2 \ifx\relax#3\relax\else v#3\space\fi #4]% + \ExplSyntaxOn + }% +\begingroup\expandafter\expandafter\expandafter\endgroup +\expandafter\ifx\csname tex\string _let:D\endcsname\relax + \expandafter\@firstofone +\else + \expandafter\@gobble +\fi + {\input{expl3-code.tex}}% +\begingroup\expandafter\expandafter\expandafter\endgroup +\expandafter\ifx\csname tex\string _let:D\endcsname\relax + \expandafter\endinput +\fi +\cs_if_exist:NF \c__expl_def_ext_tl + { \tl_const:Nn \c__expl_def_ext_tl { def } } +\cs_gset_protected:Npn \__kernel_sys_configuration_load:n #1 + { + \cs_undefine:c { ver@ #1 .def } + \@onefilewithoptions {#1} [ ] [ ] + \c__expl_def_ext_tl + } +\keys_define:nn { sys } + { + backend .choices:nn = + { dvipdfmx , dvips , dvisvgm , pdfmode , xdvipdfmx } + { \sys_load_backend:n {#1} } , + check-declarations .code:n = + { + \sys_load_debug: + \debug_on:n { check-declarations } + } , + driver .meta:n = { backend = #1 } , + enable-debug .code:n = + \sys_load_debug: , + log-functions .code:n = + { + \sys_load_debug: + \debug_on:n { log-functions } + } , + undo-recent-deprecations .code:n = + { + \sys_load_deprecation: + \bool_gset_true:N \g__kernel_deprecation_undo_recent_bool + } + } +\AtBeginDocument + { + \str_if_exist:NF \c_sys_backend_str + { \sys_load_backend:n { } } + } +\cs_if_free:cTF { ver@expl3.sty } + { + \tex_everyjob:D \exp_after:wN + { + \tex_the:D \tex_everyjob:D + \sys_everyjob: + } + } + { \sys_everyjob: } +\tl_put_left:Nn \@pushfilename + { + \exp_args:Nx \__kernel_file_input_push:n + { + \tl_to_str:N \@currname + \tl_to_str:N \@currext + } + \tl_put_left:Nx \l__expl_status_stack_tl + { + \bool_if:NTF \l__kernel_expl_bool + { 1 } + { 0 } + } + \ExplSyntaxOff + } +\tl_put_right:Nn \@pushfilename { \@pushfilenameaux } +\cs_set_protected:Npn \@pushfilenameaux #1#2#3 + { + \str_gset:Nn \g_file_curr_name_str {#3} + #1 #2 {#3} + } +\tl_put_right:Nn \@popfilename + { + \__kernel_file_input_pop: + \tl_if_empty:NTF \l__expl_status_stack_tl + { \ExplSyntaxOff } + { \exp_after:wN \__expl_status_pop:w \l__expl_status_stack_tl \q_stop } + } +\cs_new_protected:Npn \__expl_status_pop:w #1#2 \q_stop + { + \tl_set:Nn \l__expl_status_stack_tl {#2} + \int_if_odd:nTF {#1} + { \ExplSyntaxOn } + { \ExplSyntaxOff } + } +\tl_new:N \l__expl_status_stack_tl +\tl_set:Nn \l__expl_status_stack_tl { 0 } +\ExplSyntaxOff +%% +%% +%% End of file `expl3.ltx'. diff --git a/Master/texmf-dist/tex/latex/l3kernel/expl3.lua b/Master/texmf-dist/tex/latex/l3kernel/expl3.lua index e81e52a591a..835051a40fe 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/expl3.lua +++ b/Master/texmf-dist/tex/latex/l3kernel/expl3.lua @@ -41,6 +41,7 @@ local os_clock = os.clock local os_date = os.date local setcatcode = tex.setcatcode local sprint = tex.sprint +local cprint = tex.cprint local write = tex.write local utf8_char = (utf and utf.char) or unicode.utf8.char local kpse_find = (resolvers and resolvers.findfile) or kpse.find_file @@ -48,10 +49,9 @@ local function escapehex(str) write((gsub(str, ".", function (ch) return format("%02X", byte(ch)) end))) end -local charcat_table = l3kernel.charcat_table or 1 -local function charcat(charcode, catcode) - setcatcode(charcat_table, charcode, catcode) - sprint(charcat_table, utf8_char(charcode)) +local charcat +function charcat(charcode, catcode) + cprint(catcode, utf8_char(charcode)) end l3kernel.charcat = charcat local base_time = 0 diff --git a/Master/texmf-dist/tex/latex/l3kernel/expl3.sty b/Master/texmf-dist/tex/latex/l3kernel/expl3.sty index 0bec10e1004..b239fabe069 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/expl3.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/expl3.sty @@ -19,7 +19,7 @@ %% and all files in that bundle must be distributed together. %% %% File: expl3.dtx -\def\ExplFileDate{2019-10-02}% +\def\ExplFileDate{2019-10-11}% \let\ExplLoaderFileDate\ExplFileDate \ProvidesPackage{expl3} [% @@ -41,25 +41,32 @@ \ProvidesFile{#1}[#2 \ifx\relax#3\relax\else v#3\space\fi #4]% \ExplSyntaxOn }% -\input{expl3-code.tex}% +\begingroup\expandafter\expandafter\expandafter\endgroup +\expandafter\ifx\csname tex\string _let:D\endcsname\relax + \expandafter\@firstofone +\else + \expandafter\@gobble +\fi + {\input{expl3-code.tex}}% \begingroup\expandafter\expandafter\expandafter\endgroup \expandafter\ifx\csname tex\string _let:D\endcsname\relax \expandafter\endinput \fi -\tl_const:Nn \c__expl_def_ext_tl { def } -\cs_new_protected:Npn \__kernel_sys_configuration_load:n #1 +\ifdefined\@pushfilenameaux + \ExplSyntaxOn +\fi +\cs_if_exist:NF \c__expl_def_ext_tl + { \tl_const:Nn \c__expl_def_ext_tl { def } } +\cs_gset_protected:Npn \__kernel_sys_configuration_load:n #1 + { + \ExplSyntaxOff + \cs_undefine:c { ver@ #1 .def } + \@onefilewithoptions {#1} [ ] [ ] + \c__expl_def_ext_tl + \ExplSyntaxOn + } +\cs_gset_protected:Npn \__kernel_sys_configuration_load_std:n #1 { - \group_begin: - \cs_set_protected:Npn \ProvidesExplFile - { - \char_set_catcode_space:n { `\ } - \ProvidesExplFileAux - } - \cs_set_protected:Npn \ProvidesExplFileAux ##1##2##3##4 - { - \group_end: - \ProvidesFile {##1} [ ##2~v##3~##4 ] - } \cs_undefine:c { ver@ #1 .def } \@onefilewithoptions {#1} [ ] [ ] \c__expl_def_ext_tl @@ -95,6 +102,21 @@ \keys_set:nV { sys } \l__expl_options_clist \str_if_exist:NF \c_sys_backend_str { \sys_load_backend:n { } } +\cs_if_exist:NT \@pushfilenameaux + { + \cs_gset_eq:NN \__kernel_sys_configuration_load:n + \__kernel_sys_configuration_load_std:n + \endinput + } +\cs_if_free:cTF { ver@expl3.sty } + { + \tex_everyjob:D \exp_after:wN + { + \tex_the:D \tex_everyjob:D + \sys_everyjob: + } + } + { \sys_everyjob: } \tl_put_left:Nn \@pushfilename { \exp_args:Nx \__kernel_file_input_push:n @@ -132,6 +154,8 @@ } \tl_new:N \l__expl_status_stack_tl \tl_set:Nn \l__expl_status_stack_tl { 0 } +\cs_gset_eq:NN \__kernel_sys_configuration_load:n + \__kernel_sys_configuration_load_std:n %% %% %% End of file `expl3.sty'. |