summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/expl3/l3int.sty
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2006-01-12 23:55:26 +0000
committerKarl Berry <karl@freefriends.org>2006-01-12 23:55:26 +0000
commitc46a8cff75c54bb399a1879724c1ae8a37b13d66 (patch)
tree87a7949b16876363f6f43316b0443598fe5d4708 /Master/texmf-dist/tex/latex/expl3/l3int.sty
parentc13c9fba05d6822e236462817e8c1f95f220988b (diff)
expl3
git-svn-id: svn://tug.org/texlive/trunk@897 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/expl3/l3int.sty')
-rw-r--r--Master/texmf-dist/tex/latex/expl3/l3int.sty126
1 files changed, 126 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/latex/expl3/l3int.sty b/Master/texmf-dist/tex/latex/expl3/l3int.sty
new file mode 100644
index 00000000000..e745beceb25
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/expl3/l3int.sty
@@ -0,0 +1,126 @@
+%%
+%% This is file `l3int.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% l3int.dtx (with options: `package,trace')
+%%
+%%
+%% EXPERIMENTAL CODE
+%%
+%% Do not distribute this file without also distributing the
+%% source files specified above.
+%%
+%% Do not distribute a modified version of this file.
+%%
+%%
+%% File: l3int.dtx Copyright (C) 1990-1998 LaTeX3 project
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{l3int}
+ [1998/04/20 v1.0c L3 Experimental Integer module]
+\RequirePackage{l3basics}\par
+\def_new:Npn \int_incr:N #1{\tex_advance:D#1\c_one
+}
+\def_new:Npn \int_decr:N #1{\tex_advance:D#1\c_minus_one
+}
+\def_new:Npn \int_gincr:N {
+ \pref_global:D
+ \int_incr:N}
+\def_new:Npn \int_gdecr:N {
+ \pref_global:D
+ \int_decr:N}
+\def:Npn \int_incr:N #1{\int_add:Nn#1\c_one}
+\def:Npn \int_decr:N #1{\int_add:Nn#1\c_minus_one}
+\def:Npn \int_gincr:N #1{\int_gadd:Nn#1\c_one}
+\def:Npn \int_gdecr:N #1{\int_gadd:Nn#1\c_minus_one}
+\def_new:Npn \int_new:N {} % but since we don't distribute
+\let:NN \int_new:N \newcount % allocation better nick the LaTeX one ...
+\def_new:Npn \int_new:c {\exp_args:Nc \int_new:N}
+\def_new:Npn \int_set:Nn #1#2{#1#2\scan_stop:
+}
+\def_new:Npn \int_gset:Nn {
+ \pref_global:D
+ \int_set:Nn }
+\def_new:Npn \int_set:cn {\exp_args:Nc \int_set:Nn }
+\def_new:Npn \int_gset:cn {\exp_args:Nc \int_gset:Nn }
+\def_new:Npn \int_add:Nn #1#2{
+ \tex_advance:D#1#2\scan_stop:
+}
+\def_new:Npn\int_add:cn{\exp_args:Nc\int_add:Nn}
+\def_new:Npn \int_sub:Nn #1#2{
+ \tex_advance:D#1-#2\scan_stop:
+}
+\def_new:Npn \int_gadd:Nn {
+ \pref_global:D
+ \int_add:Nn }
+\def_new:Npn \int_gsub:Nn {
+ \pref_global:D
+ \int_sub:Nn }
+\let_new:NN \int_use:N \tex_the:D
+\def_new:Npn \int_use:c #1{\int_use:N \cs:w#1\cs_end:}
+
+\def_new:Npn \int_gincr:c {\exp_args:Nc \int_gincr:N}
+\def_new:Npn \int_gdecr:c {\exp_args:Nc \int_gdecr:N}
+\chk_new_cs:N \l_tmpa_int
+\tex_countdef:D\l_tmpa_int 255
+\int_new:N \l_tmpb_int
+\int_new:N \l_tmpc_int
+\int_new:N \g_tmpa_int
+\int_new:N \g_tmpb_int
+\tex_chardef:D \c_zero = 0 \scan_stop:
+\tex_chardef:D \c_one = 1 \scan_stop:
+\tex_chardef:D \c_two = 2 \scan_stop:
+\tex_chardef:D \c_three = 3 \scan_stop:
+\tex_chardef:D \c_four = 4 \scan_stop:
+\tex_chardef:D \c_sixteen = 16 \scan_stop:
+\tex_chardef:D \c_thirty_two = 32 \scan_stop:
+\tex_chardef:D \c_twohundred_fifty_five = 255 \scan_stop:
+\tex_mathchardef:D \c_twohundred_fifty_six = 256 \scan_stop:
+\tex_mathchardef:D \c_thousand = 1000 \scan_stop:
+\tex_mathchardef:D \c_ten_thousand = 10000 \scan_stop:
+\tex_mathchardef:D \c_ten_thousand_one = 10001 \scan_stop:
+\tex_mathchardef:D \c_ten_thousand_two = 10002 \scan_stop:
+\tex_mathchardef:D \c_ten_thousand_three = 10003 \scan_stop:
+\tex_mathchardef:D \c_ten_thousand_four = 10004 \scan_stop:
+\tex_mathchardef:D \c_twenty_thousand = 20000 \scan_stop:
+\let_new:NN \fint_new:N \newmuskip % nicked from LaTeX
+\def_new:Npn \fint_use:N {\exp_after:NN\fint_use_aux:w\the_internal:D}
+\tex_lccode:D`\!=`\m \tex_lccode:D`\?=`\u
+\tex_lowercase:D{\def_new:Npn \fint_use_aux:w #1.0!?{#1}}
+\tex_lccode:D`\!=0\scan_stop: \tex_lccode:D`\?=0\scan_stop:
+\def_new:Npn \fint_set:Nn #1#2{#1#2~mu\scan_stop:
+}
+\def_new:Npn \fint_gset:Nn{
+ \pref_global:D
+ \fint_set:Nn}
+\def_new:Npn \fint_set_eq:NN #1#2{#1#2
+}
+\def_new:Npn \fint_gset_eq:NN {
+ \pref_global:D
+ \fint_set_eq:NN}
+\def_new:Npn \fint_add:Nn #1#2{\int_add:Nn#1{#2mu}}
+\def_new:Npn \fint_gadd:Nn {
+ \pref_global:D
+ \fint_add:Nn}
+\def_new:Npn \fint_sub:Nn #1#2{\int_sub:Nn#1{#2mu}}
+\def_new:Npn \fint_gsub:Nn {
+ \pref_global:D
+ \fint_sub:Nn}
+\def_new:Npn \fint_incr:N #1{\advance:D#1\c_one mu\scan_stop:
+}
+\def_new:Npn \fint_decr:N #1{\advance:D#1\c_minus_one mu\scan_stop:
+}
+\def_new:Npn \fint_gincr:N {
+ \pref_global:D
+ \fint_incr:N}
+\def_new:Npn \fint_gdecr:N {
+ \pref_global:D
+ \fint_decr:N}
+\def:Npn \fint_incr:N #1{\fint_add:Nn#1\c_one}
+\def:Npn \fint_decr:N #1{\fint_add:Nn#1\c_minus_one}
+\tex_mathchardef:D\c_fint_max=16383 \scan_stop:
+
+%%
+%%
+%% End of file `l3int.sty'.