blob: f476f13272d94c875fe4db1b16b72a3bf08b1674 [file] [log] [blame]
Guido van Rossuma3309961993-07-28 09:05:47 +00001#ifndef Py_MODSUPPORT_H
2#define Py_MODSUPPORT_H
3#ifdef __cplusplus
4extern "C" {
5#endif
6
Guido van Rossumf70e43a1991-02-19 12:39:46 +00007/***********************************************************
Guido van Rossume5372401993-03-16 12:15:04 +00008Copyright 1991, 1992, 1993 by Stichting Mathematisch Centrum,
9Amsterdam, The Netherlands.
Guido van Rossumf70e43a1991-02-19 12:39:46 +000010
11 All Rights Reserved
12
13Permission to use, copy, modify, and distribute this software and its
14documentation for any purpose and without fee is hereby granted,
15provided that the above copyright notice appear in all copies and that
16both that copyright notice and this permission notice appear in
17supporting documentation, and that the names of Stichting Mathematisch
18Centrum or CWI not be used in advertising or publicity pertaining to
19distribution of the software without specific, written prior permission.
20
21STICHTING MATHEMATISCH CENTRUM DISCLAIMS ALL WARRANTIES WITH REGARD TO
22THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
23FITNESS, IN NO EVENT SHALL STICHTING MATHEMATISCH CENTRUM BE LIABLE
24FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
25WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
26ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
27OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
28
29******************************************************************/
30
Guido van Rossum85a5fbb1990-10-14 12:07:46 +000031/* Module support interface */
32
Guido van Rossume5372401993-03-16 12:15:04 +000033#ifdef HAVE_PROTOTYPES
34#define USE_STDARG
35#endif
36
37#ifdef USE_STDARG
38#include <stdarg.h>
39#else
40#include <varargs.h>
41#endif
42
Guido van Rossum85a5fbb1990-10-14 12:07:46 +000043extern object *initmodule PROTO((char *, struct methodlist *));
Guido van Rossum550fbcc1992-01-27 16:50:21 +000044extern int getargs PROTO((object *, char *, ...));
Guido van Rossume5372401993-03-16 12:15:04 +000045extern int vgetargs PROTO((object *, char *, va_list));
Guido van Rossum5a8f8241992-04-13 15:54:59 +000046extern object *mkvalue PROTO((char *, ...));
Guido van Rossume5372401993-03-16 12:15:04 +000047extern object *vmkvalue PROTO((char *, va_list));
Guido van Rossum550fbcc1992-01-27 16:50:21 +000048
Guido van Rossum234f9421993-06-17 12:35:49 +000049/* The following are obsolete -- use getargs directly! */
Guido van Rossum550fbcc1992-01-27 16:50:21 +000050#define getnoarg(v) getargs(v, "")
51#define getintarg(v, a) getargs(v, "i", a)
Guido van Rossum550fbcc1992-01-27 16:50:21 +000052#define getlongarg(v, a) getargs(v, "l", a)
Guido van Rossum550fbcc1992-01-27 16:50:21 +000053#define getstrarg(v, a) getargs(v, "s", a)
Guido van Rossuma3309961993-07-28 09:05:47 +000054
55#ifdef __cplusplus
56}
57#endif
58#endif /* !Py_MODSUPPORT_H */