summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/xsim/xsim.verbwrite.code.tex
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/xsim/xsim.verbwrite.code.tex')
-rw-r--r--Master/texmf-dist/tex/latex/xsim/xsim.verbwrite.code.tex15
1 files changed, 10 insertions, 5 deletions
diff --git a/Master/texmf-dist/tex/latex/xsim/xsim.verbwrite.code.tex b/Master/texmf-dist/tex/latex/xsim/xsim.verbwrite.code.tex
index a04ab8fed43..4738dc77868 100644
--- a/Master/texmf-dist/tex/latex/xsim/xsim.verbwrite.code.tex
+++ b/Master/texmf-dist/tex/latex/xsim/xsim.verbwrite.code.tex
@@ -103,10 +103,18 @@
% see http://tex.stackexchange.com/q/9035/5049 reasons
\use:nx
{ \__xsim_file_write_start:n {#2} }
- { \bool_if:nF {#1} { \c__xsim_active_eol_tl } }
+ { \bool_if:nF {#1} { \exp_not:V \c__xsim_active_eol_tl } }
}
\cs_generate_variant:Nn \xsim_file_write_start:nn {nV}
+\cs_new_protected:Npn \__xsim_set_verb_catcodes:
+ {
+ \seq_map_inline:Nn \l_char_special_seq
+ { \char_set_catcode_other:N ##1 }
+ \int_step_inline:nnnn {128} {1} {255}
+ { \char_set_catcode_letter:n {##1} }
+ }
+
\group_begin:
\char_set_catcode_active:n {13} % ^^M (carriage return, endlinechar)
\char_set_catcode_active:n {12} % ^^L (form feed)
@@ -130,10 +138,7 @@
{ \l_xsim_file_begin_tl } %
} %
} %
- \seq_map_inline:Nn \l_char_special_seq %
- { \char_set_catcode_other:N ##1 } %
- \int_step_inline:nnnn {128} {1} {255} %
- { \char_set_catcode_letter:n {##1} } %
+ \__xsim_set_verb_catcodes: %
\tl_set:Nx \l__xsim_tmpa_tl %
{ \c__xsim_backslash_char_tl end \cs_to_str:N \{ \@currenvir \cs_to_str:N \} } %
\use:x %