Mercurial > cpython-lru_cache-weakref
diff Include/floatobject.h @ 6:fc6fcd7df4f7 legacy-trunk
Initial revision
| author | Guido van Rossum <guido@python.org> |
|---|---|
| date | Sun, 14 Oct 1990 12:07:46 +0000 |
| parents | |
| children | 853b736a6a9e |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Include/floatobject.h Sun Oct 14 12:07:46 1990 +0000 @@ -0,0 +1,20 @@ +/* Float object interface */ + +/* +floatobject represents a (double precision) floating point number. +*/ + +typedef struct { + OB_HEAD + double ob_fval; +} floatobject; + +extern typeobject Floattype; + +#define is_floatobject(op) ((op)->ob_type == &Floattype) + +extern object *newfloatobject PROTO((double)); +extern double getfloatvalue PROTO((object *)); + +/* Macro, trading safety for speed */ +#define GETFLOATVALUE(op) ((op)->ob_fval)
