summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/l3kernel/l3fp-round.dtx
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2018-04-30 22:39:09 +0000
committerKarl Berry <karl@freefriends.org>2018-04-30 22:39:09 +0000
commita28e1bfccd6fe522fcd296426e4d89c7fb4f19b6 (patch)
treeb72347e08575b56fcfed87c4d837b48dcfd1e02a /Master/texmf-dist/source/latex/l3kernel/l3fp-round.dtx
parentb40c37a9e22b8235ff9c0bc256d00f7af94304c3 (diff)
l3 (30apr18)
git-svn-id: svn://tug.org/texlive/trunk@47516 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/l3kernel/l3fp-round.dtx')
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-round.dtx46
1 files changed, 24 insertions, 22 deletions
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-round.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-round.dtx
index 5636ff51d8a..da019daf60f 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-round.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-round.dtx
@@ -41,7 +41,7 @@
% }^^A
% }
%
-% \date{Released 2018/03/05}
+% \date{Released 2018-04-30}
%
% \maketitle
%
@@ -166,7 +166,7 @@
% \meta{digit_1}.\meta{digit_2}$ to an integer rounds it towards zero
% (truncates it), this function expands to |0\exp_stop_f:|, and otherwise
% to |1\exp_stop_f:|. Typically used within the scope of an
-% \cs{__int_eval:w}, to add~$1$ if needed, and thereby round
+% \cs{@@_int_eval:w}, to add~$1$ if needed, and thereby round
% correctly. The result depends on the rounding mode.
%
% It is very important that \meta{final sign} be the final sign of the
@@ -272,7 +272,7 @@
% \meta{digit}.\meta{more digits}$ to an integer truncates, and to
% |1\exp_stop_f:;| otherwise. The \meta{more digits} part must be a digit,
% followed by something that does not overflow a \cs{int_use:N}
-% \cs{__int_eval:w} construction. The only relevant information about
+% \cs{@@_int_eval:w} construction. The only relevant information about
% this piece is whether it is zero or not.
% \begin{macrocode}
\cs_new:Npn \@@_round_s:NNNw #1 #2 #3 #4;
@@ -280,11 +280,11 @@
\exp_after:wN \@@_round:NNN
\exp_after:wN #1
\exp_after:wN #2
- \__int_value:w \__int_eval:w
+ \int_value:w \@@_int_eval:w
\if_int_odd:w 0 \if_meaning:w 0 #3 1 \fi:
\if_meaning:w 5 #3 1 \fi:
\exp_stop_f:
- \if_int_compare:w \__int_eval:w #4 > 0 \exp_stop_f:
+ \if_int_compare:w \@@_int_eval:w #4 > 0 \exp_stop_f:
1 +
\fi:
\fi:
@@ -296,11 +296,11 @@
%
% \begin{macro}[EXP]{\@@_round_digit:Nw}
% \begin{syntax}
-% \cs{__int_value:w} \cs{@@_round_digit:Nw} \meta{digit} \meta{intexpr} |;|
+% \cs{int_value:w} \cs{@@_round_digit:Nw} \meta{digit} \meta{intexpr} |;|
% \end{syntax}
-% This function should always be called within an \cs{__int_value:w}
-% or \cs{__int_eval:w} expansion; it may add an extra
-% \cs{__int_eval:w}, which means that the integer or integer
+% This function should always be called within an \cs{int_value:w}
+% or \cs{@@_int_eval:w} expansion; it may add an extra
+% \cs{@@_int_eval:w}, which means that the integer or integer
% expression should not be ended with a synonym of \tn{relax}, but
% with a semi-colon for instance.
% \begin{macrocode}
@@ -309,8 +309,8 @@
\if_int_odd:w \if_meaning:w 0 #1 1 \else:
\if_meaning:w 5 #1 1 \else:
0 \fi: \fi: \exp_stop_f:
- \if_int_compare:w \__int_eval:w #2 > 0 \exp_stop_f:
- \__int_eval:w 1 +
+ \if_int_compare:w \@@_int_eval:w #2 > 0 \exp_stop_f:
+ \@@_int_eval:w 1 +
\fi:
\fi:
#1
@@ -355,7 +355,8 @@
}
\cs_new_eq:NN \@@_round_to_pinf_neg:NNN \@@_round_to_ninf:NNN
\cs_new_eq:NN \@@_round_to_nearest_neg:NNN \@@_round_to_nearest:NNN
-\cs_new_eq:NN \@@_round_to_nearest_ninf_neg:NNN \@@_round_to_nearest_pinf:NNN
+\cs_new_eq:NN \@@_round_to_nearest_ninf_neg:NNN
+ \@@_round_to_nearest_pinf:NNN
\cs_new:Npn \@@_round_to_nearest_zero_neg:NNN #1 #2 #3
{
\if_int_compare:w #3 < \c_@@_five_int \else:
@@ -363,7 +364,8 @@
\fi:
0 \exp_stop_f:
}
-\cs_new_eq:NN \@@_round_to_nearest_pinf_neg:NNN \@@_round_to_nearest_ninf:NNN
+\cs_new_eq:NN \@@_round_to_nearest_pinf_neg:NNN
+ \@@_round_to_nearest_ninf:NNN
\cs_new_eq:NN \@@_round_neg:NNN \@@_round_to_nearest_neg:NNN
% \end{macrocode}
% \end{macro}
@@ -390,7 +392,7 @@
\cs_new:Npn \@@_round_aux_o:Nw #1#2 @
{
\if_case:w
- \__int_eval:w \@@_array_count:n {#2} \__int_eval_end:
+ \@@_int_eval:w \@@_array_count:n {#2} \@@_int_eval_end:
\@@_round_no_arg_o:Nw #1 \exp:w
\or: \@@_round:Nwn #1 #2 {0} \exp:w
\or: \@@_round:Nww #1 #2 \exp:w
@@ -494,7 +496,7 @@
\if_meaning:w 1 #2
\exp_after:wN \@@_round_normal:NwNNnw
\exp_after:wN #1
- \__int_value:w #5
+ \int_value:w #5
\else:
\exp_after:wN \@@_exp_after_o:w
\fi:
@@ -508,25 +510,25 @@
\cs_new:Npn \@@_round_normal:NnnwNNnn #1#2#3#4; #5#6
{
\exp_after:wN \@@_round_normal:NNwNnn
- \__int_value:w \__int_eval:w
+ \int_value:w \@@_int_eval:w
\if_int_compare:w #2 > 0 \exp_stop_f:
- 1 \__int_value:w #2
+ 1 \int_value:w #2
\exp_after:wN \@@_round_pack:Nw
- \__int_value:w \__int_eval:w 1#3 +
+ \int_value:w \@@_int_eval:w 1#3 +
\else:
\if_int_compare:w #3 > 0 \exp_stop_f:
- 1 \__int_value:w #3 +
+ 1 \int_value:w #3 +
\fi:
\fi:
\exp_after:wN #5
\exp_after:wN #6
\use_none:nnnnnnn #3
#1
- \__int_eval_end:
+ \@@_int_eval_end:
0000 0000 0000 0000 ; #6
}
\cs_new:Npn \@@_round_pack:Nw #1
- { \if_meaning:w 2 #1 + 1 \fi: \__int_eval_end: }
+ { \if_meaning:w 2 #1 + 1 \fi: \@@_int_eval_end: }
\cs_new:Npn \@@_round_normal:NNwNnn #1 #2
{
\if_meaning:w 0 #2
@@ -551,7 +553,7 @@
\else:
\exp_after:wN \@@_round_special_aux:Nw
\exp_after:wN #4
- \__int_value:w \__int_eval:w 1
+ \int_value:w \@@_int_eval:w 1
\if_meaning:w 1 #1 -#6 \else: +#5 \fi:
\fi:
;