From 37779918ae3fb37b74b1153c61c19b3e3c8aa501 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Mon, 13 May 2013 23:46:45 +0000 Subject: memory (13may13) git-svn-id: svn://tug.org/texlive/trunk@30452 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/tex/latex/memory/memory.sty | 46 +++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 Master/texmf-dist/tex/latex/memory/memory.sty (limited to 'Master/texmf-dist/tex/latex/memory') diff --git a/Master/texmf-dist/tex/latex/memory/memory.sty b/Master/texmf-dist/tex/latex/memory/memory.sty new file mode 100644 index 00000000000..19c1d68c83f --- /dev/null +++ b/Master/texmf-dist/tex/latex/memory/memory.sty @@ -0,0 +1,46 @@ +%% +%% This is file `memory.sty', +%% generated with the docstrip utility. +%% +%% The original source files were: +%% +%% memory.dtx (with options: `memory') +%% +%% This is a generated file. +%% +%% Copyright (C) 2013 by Song Zhiwei +%% +%% This file may be distributed and/or modified under the conditions of +%% the LaTeX Project Public License, either version 1.3c of this license +%% or (at your option) any later version. The latest version of this +%% license is in: +%% +%% http://www.latex-project.org/lppl.txt 32 +%% +%% and version 1.3c or later is part of all distributions of LaTeX +%% version 2006/05/20 or later. +%% +\NeedsTeXFormat{LaTeX2e}[2003/12/01] +\ProvidesPackage{memory} + [2013/05/13 v1.2 containers for data of object and array in LaTeX] +\def\set@memory#1#2=#3{\if#1*\expandafter\gdef\csname#2\endcsname{#3}% + \else\expandafter\def\csname#2\endcsname{#3}\fi} +\def\eset@memory#1#2=#3{\if#1*\expandafter\xdef\csname#2\endcsname{#3}% + \else\expandafter\edef\csname#2\endcsname{#3}\fi} +\def\etest@memory#1#2:{\@ifnextchar={\eset@memory{#1}{#2}} + {\csname #2\endcsname:}} +\def\data@memory#1#2{\@ifnextchar={\set@memory{#1}{@#2@memory}} + {\@ifnextchar:{\etest@memory{#1}{@#2@memory}} + {\csname @#2@memory\endcsname}}} +\def\array@memory#1#2[#3]{\data@memory{#1}{#2@#3}} +\def\newdata@memory#1#2{\@ifundefined{#2} + {\if#1*\expandafter\gdef\csname#2\endcsname{\@ifnextchar[ + {\array@memory{#1}{#2}}{\data@memory{#1}{#2}}}% + \else \expandafter\def\csname#2\endcsname{\@ifnextchar[ + {\array@memory{#1}{#2}}{\data@memory{#1}{#2}}}\fi} + {\PackageWarningNoLine{memory}{`#2' already defined. + Macro `newdata' ignored!}}} +\def\newdata{\@ifnextchar*{\newdata@memory}{\newdata@memory{}}} +\endinput +%% +%% End of file `memory.sty'. -- cgit v1.2.3