summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/l3kernel/l3io.dtx
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2011-12-11 22:32:04 +0000
committerKarl Berry <karl@freefriends.org>2011-12-11 22:32:04 +0000
commit3cc0c51eddc31f37b82f651016191bf3575f3aac (patch)
tree85e3f4cfbe245c416571020e0eb1136193596550 /Master/texmf-dist/source/latex/l3kernel/l3io.dtx
parentc56f30c6154e55286a21f438d5ed545a5169f13b (diff)
l3kernel 3036 (11dec11)
git-svn-id: svn://tug.org/texlive/trunk@24822 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/l3kernel/l3io.dtx')
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3io.dtx59
1 files changed, 16 insertions, 43 deletions
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3io.dtx b/Master/texmf-dist/source/latex/l3kernel/l3io.dtx
index b31b0a3f8c3..991e02e6af8 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3io.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3io.dtx
@@ -35,7 +35,7 @@
%
%<*driver|package>
\RequirePackage{l3names}
-\GetIdInfo$Id: l3io.dtx 2896 2011-10-09 20:36:50Z joseph $
+\GetIdInfo$Id: l3io.dtx 3005 2011-11-25 13:19:47Z bruno $
{L3 Experimental input-output operations}
%</driver|package>
%<*driver>
@@ -759,53 +759,28 @@
% \end{macro}
% \end{macro}
%
+%
% \begin{macro}{\ior_list_streams:}
-% \begin{macro}{\iow_list_streams:}
-% \begin{macro}[aux]{\iow_show_aux:nn}
-% \begin{macro}[aux]{\ior_show_aux:nn}
-% Show the property lists, but with some \enquote{pretty printing}.
+% Show the property lists, but with some \enquote{pretty printing}.
+% See the \pkg{l3msg} module. If there are no open read streams,
+% issue the message \texttt{show-no-stream}, and show an empty
+% token list. If there are open read streams, format them with
+% \cs{msg_aux_show_unbraced:nn}, and with the message
+% \texttt{show-open-streams}.
% \begin{macrocode}
\cs_new_protected_nopar:Npn \ior_list_streams:
- {
- \prop_if_empty:NTF \g_ior_streams_prop
- {
- \iow_term:x { No~input~streams~are~open }
- \tl_show:n { }
- }
- {
- \iow_term:x { The~following~input~streams~are~in~use: }
- \tl_set:Nx \l_prop_show_tl
- { \prop_map_function:NN \g_ior_streams_prop \ior_show_aux:nn }
- \etex_showtokens:D \exp_after:wN \exp_after:wN \exp_after:wN
- { \exp_after:wN \prop_show_aux:w \l_prop_show_tl }
- }
- }
-\cs_new:Npn \ior_show_aux:nn #1#2
- {
- \iow_newline: > \c_space_tl \c_space_tl
- #1 \c_space_tl \c_space_tl => \c_space_tl \c_space_tl \exp_not:n {#2}
- }
+ { \ior_list_streams_aux:Nn \g_ior_streams_prop { ior } }
\cs_new_protected_nopar:Npn \iow_list_streams:
+ { \ior_list_streams_aux:Nn \g_iow_streams_prop { iow } }
+\cs_new_protected:Npn \ior_list_streams_aux:Nn #1#2
{
- \prop_if_empty:NTF \g_iow_streams_prop
- {
- \iow_term:x { No~output~streams~are~open }
- \tl_show:n { }
- }
- {
- \iow_term:x { The~following~output~streams~are~in~use: }
- \tl_set:Nx \l_prop_show_tl
- { \prop_map_function:NN \g_iow_streams_prop \iow_show_aux:nn }
- \etex_showtokens:D \exp_after:wN \exp_after:wN \exp_after:wN
- { \exp_after:wN \prop_show_aux:w \l_prop_show_tl }
- }
+ \msg_aux_use:nn { LaTeX / #2 }
+ { \prop_if_empty:NTF #1 { show-no-stream } { show-open-streams } }
+ \msg_aux_show:x
+ { \prop_map_function:NN #1 \msg_aux_show_unbraced:nn }
}
-\cs_new_eq:NN \iow_show_aux:nn \ior_show_aux:nn
% \end{macrocode}
% \end{macro}
-% \end{macro}
-% \end{macro}
-% \end{macro}
%
% Text for the error messages.
% \begin{macrocode}
@@ -1194,9 +1169,7 @@
% \begin{macrocode}
\cs_new_protected_nopar:Npn \iow_wrap_special:w #1 ~ #2 ~ #3 ~ %
{
- \cs_if_exist:cTF { iow_wrap_#1: }
- { \use:c { iow_wrap_#1: } }
- { \msg_expandable_error:n {#1} }
+ \use:c { iow_wrap_#1: }
\str_if_eq:xxTF { #2~#3 } { ~ \c_iow_wrap_marker_tl }
{ \iow_wrap_special:w }
{ \iow_wrap_loop:w #2 ~ #3 ~ }