|
|
DataMuseum.dkPresents historical artifacts from the history of: DKUUG/EUUG Conference tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about DKUUG/EUUG Conference tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: T i
Length: 674 (0x2a2)
Types: TextFile
Names: »integer.c«
└─⟦2d1937cfd⟧ Bits:30007241 EUUGD22: P.P 5.0
└─⟦35176feda⟧ »EurOpenD22/isode/isode-6.tar.Z«
└─⟦de7628f85⟧
└─⟦this⟧ »isode-6.0/dsap/common/integer.c«
/* LINTLIBRARY */
#include "quipu/util.h"
#include "quipu/attr.h"
#include "psap.h"
atoi();
static PE intenc (x)
int x;
{
return (int2prim(x));
}
static intdec (pe)
PE pe;
{
if (! test_prim_pe (pe,PE_CLASS_UNIV,PE_PRIM_INT))
return (0);
return (prim2num(pe));
}
/* ARGSUSED */
static intprint (ps,x,format)
PS ps;
int x,format;
{
ps_printf (ps,"%d",x);
}
static intdup (x)
int x;
{
return (x);
}
static intcmp (x,y)
int x,y;
{
return ( x == y ? 0 : (x > y ? 1 : -1) );
}
integer_syntax ()
{
(void) add_attribute_syntax ("integer",
(IFP) intenc, (IFP) intdec,
(IFP) atoi, intprint,
(IFP) intdup, intcmp,
NULLIFP, NULLCP,
NULLIFP, FALSE);
}