summaryrefslogtreecommitdiffstats
path: root/Parser
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1993-07-28 09:05:47 (GMT)
committerGuido van Rossum <guido@python.org>1993-07-28 09:05:47 (GMT)
commita3309960a50dbadfd854299e7420223eb8718a56 (patch)
tree450507606b30e153bcd20d61c3cc0571a246457d /Parser
parentf6da4f62b41db6f50481ae300b4997856638399c (diff)
downloadcpython-a3309960a50dbadfd854299e7420223eb8718a56.zip
cpython-a3309960a50dbadfd854299e7420223eb8718a56.tar.gz
cpython-a3309960a50dbadfd854299e7420223eb8718a56.tar.bz2
* Added support for X11 modules.
* Makefile: change location of FORMS library. * posixmodule.c: turn #if 0 into #ifdef MSDOS (stuff in unistd.h or not) * Almost all .h files: added CPP magic to avoid duplicate inclusions and to support inclusion from C++.
Diffstat (limited to 'Parser')
-rw-r--r--Parser/assert.h11
-rw-r--r--Parser/parser.h11
-rw-r--r--Parser/pgen.h11
-rw-r--r--Parser/tokenizer.h11
4 files changed, 44 insertions, 0 deletions
diff --git a/Parser/assert.h b/Parser/assert.h
index ac9c5d2..dbce369 100644
--- a/Parser/assert.h
+++ b/Parser/assert.h
@@ -1,3 +1,9 @@
+#ifndef Py_ASSERT_H
+#define Py_ASSERT_H
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/***********************************************************
Copyright 1991, 1992, 1993 by Stichting Mathematisch Centrum,
Amsterdam, The Netherlands.
@@ -23,3 +29,8 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
******************************************************************/
#define assert(e) { if (!(e)) { printf("Assertion failed\n"); abort(); } }
+
+#ifdef __cplusplus
+}
+#endif
+#endif /* !Py_ASSERT_H */
diff --git a/Parser/parser.h b/Parser/parser.h
index 0763312..b025a50 100644
--- a/Parser/parser.h
+++ b/Parser/parser.h
@@ -1,3 +1,9 @@
+#ifndef Py_PARSER_H
+#define Py_PARSER_H
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/***********************************************************
Copyright 1991, 1992, 1993 by Stichting Mathematisch Centrum,
Amsterdam, The Netherlands.
@@ -48,3 +54,8 @@ parser_state *newparser PROTO((struct _grammar *g, int start));
void delparser PROTO((parser_state *ps));
int addtoken PROTO((parser_state *ps, int type, char *str, int lineno));
void addaccelerators PROTO((grammar *g));
+
+#ifdef __cplusplus
+}
+#endif
+#endif /* !Py_PARSER_H */
diff --git a/Parser/pgen.h b/Parser/pgen.h
index 948f5a5..872a3fa 100644
--- a/Parser/pgen.h
+++ b/Parser/pgen.h
@@ -1,3 +1,9 @@
+#ifndef Py_PGEN_H
+#define Py_PGEN_H
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/***********************************************************
Copyright 1991, 1992, 1993 by Stichting Mathematisch Centrum,
Amsterdam, The Netherlands.
@@ -30,3 +36,8 @@ extern grammar *meta_grammar PROTO((void));
struct _node;
extern grammar *pgen PROTO((struct _node *));
+
+#ifdef __cplusplus
+}
+#endif
+#endif /* !Py_PGEN_H */
diff --git a/Parser/tokenizer.h b/Parser/tokenizer.h
index bdef859..17f44e5 100644
--- a/Parser/tokenizer.h
+++ b/Parser/tokenizer.h
@@ -1,3 +1,9 @@
+#ifndef Py_TOKENIZER_H
+#define Py_TOKENIZER_H
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/***********************************************************
Copyright 1991, 1992, 1993 by Stichting Mathematisch Centrum,
Amsterdam, The Netherlands.
@@ -54,3 +60,8 @@ extern struct tok_state *tok_setups PROTO((char *));
extern struct tok_state *tok_setupf PROTO((FILE *, char *ps1, char *ps2));
extern void tok_free PROTO((struct tok_state *));
extern int tok_get PROTO((struct tok_state *, char **, char **));
+
+#ifdef __cplusplus
+}
+#endif
+#endif /* !Py_TOKENIZER_H */