annotate Python/getopt.c @ 80503:d2df83d7c649 2.7

#16306: Fix multiple error messages when unknown command line parameters where passed to the interpreter. Patch by Hieu Nguyen.
author Ezio Melotti <ezio.melotti@gmail.com>
date Sun, 18 Nov 2012 13:46:38 +0200
parents 0abffbe7cf22
children 6a79e3beb854
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1598
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
1 /*---------------------------------------------------------------------------*
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
2 * <RCS keywords>
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
3 *
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
4 * C++ Library
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
5 *
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
6 * Copyright 1992-1994, David Gottner
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
7 *
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
8 * All Rights Reserved
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
9 *
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
10 * Permission to use, copy, modify, and distribute this software and its
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
11 * documentation for any purpose and without fee is hereby granted,
1598
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
12 * provided that the above copyright notice, this permission notice and
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
13 * the following disclaimer notice appear unmodified in all copies.
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
14 *
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
15 * I DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
16 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL I
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
17 * BE LIABLE FOR ANY SPECIAL, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
18 * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA, OR PROFITS, WHETHER
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
19 * IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
20 * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
21 *
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
22 * Nevertheless, I would like to know about bugs in this library or
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
23 * suggestions for improvment. Send bug reports and feedback to
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
24 * davegottner@delphi.com.
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
25 *---------------------------------------------------------------------------*/
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
26
39073
c48b3a68f696 Accept long options "--help" and "--version".
Georg Brandl <georg@python.org>
parents: 37655
diff changeset
27 /* Modified to support --help and --version, as well as /? on Windows
c48b3a68f696 Accept long options "--help" and "--version".
Georg Brandl <georg@python.org>
parents: 37655
diff changeset
28 * by Georg Brandl. */
c48b3a68f696 Accept long options "--help" and "--version".
Georg Brandl <georg@python.org>
parents: 37655
diff changeset
29
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
30 #include <stdio.h>
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
31 #include <string.h>
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
32
37655
2f3f2e32dfd9 spread the extern "C" { } magic pixie dust around. Python itself builds now
Anthony Baxter <anthonybaxter@gmail.com>
parents: 15374
diff changeset
33 #ifdef __cplusplus
2f3f2e32dfd9 spread the extern "C" { } magic pixie dust around. Python itself builds now
Anthony Baxter <anthonybaxter@gmail.com>
parents: 15374
diff changeset
34 extern "C" {
2f3f2e32dfd9 spread the extern "C" { } magic pixie dust around. Python itself builds now
Anthony Baxter <anthonybaxter@gmail.com>
parents: 15374
diff changeset
35 #endif
2f3f2e32dfd9 spread the extern "C" { } magic pixie dust around. Python itself builds now
Anthony Baxter <anthonybaxter@gmail.com>
parents: 15374
diff changeset
36
15374
a826a46bae54 Move our own getopt() implementation to _PyOS_GetOpt(), and use it
Thomas Wouters <thomas@python.org>
parents: 13658
diff changeset
37 int _PyOS_opterr = 1; /* generate error messages */
a826a46bae54 Move our own getopt() implementation to _PyOS_GetOpt(), and use it
Thomas Wouters <thomas@python.org>
parents: 13658
diff changeset
38 int _PyOS_optind = 1; /* index into argv array */
a826a46bae54 Move our own getopt() implementation to _PyOS_GetOpt(), and use it
Thomas Wouters <thomas@python.org>
parents: 13658
diff changeset
39 char *_PyOS_optarg = NULL; /* optional argument */
75147
0abffbe7cf22 Fix crash at startup with -W options.
Antoine Pitrou <solipsis@pitrou.net>
parents: 61463
diff changeset
40 static char *opt_ptr = "";
0abffbe7cf22 Fix crash at startup with -W options.
Antoine Pitrou <solipsis@pitrou.net>
parents: 61463
diff changeset
41
0abffbe7cf22 Fix crash at startup with -W options.
Antoine Pitrou <solipsis@pitrou.net>
parents: 61463
diff changeset
42 void _PyOS_ResetGetOpt(void)
0abffbe7cf22 Fix crash at startup with -W options.
Antoine Pitrou <solipsis@pitrou.net>
parents: 61463
diff changeset
43 {
80503
d2df83d7c649 #16306: Fix multiple error messages when unknown command line parameters where passed to the interpreter. Patch by Hieu Nguyen.
Ezio Melotti <ezio.melotti@gmail.com>
parents: 75147
diff changeset
44 _PyOS_opterr = 0; /* prevent printing the error in 2nd loop in main.c */
75147
0abffbe7cf22 Fix crash at startup with -W options.
Antoine Pitrou <solipsis@pitrou.net>
parents: 61463
diff changeset
45 _PyOS_optind = 1;
0abffbe7cf22 Fix crash at startup with -W options.
Antoine Pitrou <solipsis@pitrou.net>
parents: 61463
diff changeset
46 _PyOS_optarg = NULL;
0abffbe7cf22 Fix crash at startup with -W options.
Antoine Pitrou <solipsis@pitrou.net>
parents: 61463
diff changeset
47 opt_ptr = "";
0abffbe7cf22 Fix crash at startup with -W options.
Antoine Pitrou <solipsis@pitrou.net>
parents: 61463
diff changeset
48 }
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
49
15374
a826a46bae54 Move our own getopt() implementation to _PyOS_GetOpt(), and use it
Thomas Wouters <thomas@python.org>
parents: 13658
diff changeset
50 int _PyOS_GetOpt(int argc, char **argv, char *optstring)
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
51 {
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
52 char *ptr;
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
53 int option;
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
54
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
55 if (*opt_ptr == '\0') {
1598
ecbadb818847 New version handles -o<string> same as -o <string>
Guido van Rossum <guido@python.org>
parents: 1585
diff changeset
56
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
57 if (_PyOS_optind >= argc)
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
58 return -1;
39073
c48b3a68f696 Accept long options "--help" and "--version".
Georg Brandl <georg@python.org>
parents: 37655
diff changeset
59 #ifdef MS_WINDOWS
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
60 else if (strcmp(argv[_PyOS_optind], "/?") == 0) {
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
61 ++_PyOS_optind;
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
62 return 'h';
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
63 }
39073
c48b3a68f696 Accept long options "--help" and "--version".
Georg Brandl <georg@python.org>
parents: 37655
diff changeset
64 #endif
c48b3a68f696 Accept long options "--help" and "--version".
Georg Brandl <georg@python.org>
parents: 37655
diff changeset
65
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
66 else if (argv[_PyOS_optind][0] != '-' ||
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
67 argv[_PyOS_optind][1] == '\0' /* lone dash */ )
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
68 return -1;
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
69
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
70 else if (strcmp(argv[_PyOS_optind], "--") == 0) {
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
71 ++_PyOS_optind;
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
72 return -1;
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
73 }
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
74
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
75 else if (strcmp(argv[_PyOS_optind], "--help") == 0) {
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
76 ++_PyOS_optind;
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
77 return 'h';
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
78 }
39073
c48b3a68f696 Accept long options "--help" and "--version".
Georg Brandl <georg@python.org>
parents: 37655
diff changeset
79
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
80 else if (strcmp(argv[_PyOS_optind], "--version") == 0) {
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
81 ++_PyOS_optind;
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
82 return 'V';
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
83 }
39073
c48b3a68f696 Accept long options "--help" and "--version".
Georg Brandl <georg@python.org>
parents: 37655
diff changeset
84
c48b3a68f696 Accept long options "--help" and "--version".
Georg Brandl <georg@python.org>
parents: 37655
diff changeset
85
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
86 opt_ptr = &argv[_PyOS_optind++][1];
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
87 }
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
88
80503
d2df83d7c649 #16306: Fix multiple error messages when unknown command line parameters where passed to the interpreter. Patch by Hieu Nguyen.
Ezio Melotti <ezio.melotti@gmail.com>
parents: 75147
diff changeset
89 if ((option = *opt_ptr++) == '\0')
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
90 return -1;
46406
c1fa2e758e05 Applied patch #2617 from Frank Wierzbicki wit some extras from me
Christian Heimes <christian@cheimes.de>
parents: 39073
diff changeset
91
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
92 if (option == 'J') {
80503
d2df83d7c649 #16306: Fix multiple error messages when unknown command line parameters where passed to the interpreter. Patch by Hieu Nguyen.
Ezio Melotti <ezio.melotti@gmail.com>
parents: 75147
diff changeset
93 if (_PyOS_opterr)
d2df83d7c649 #16306: Fix multiple error messages when unknown command line parameters where passed to the interpreter. Patch by Hieu Nguyen.
Ezio Melotti <ezio.melotti@gmail.com>
parents: 75147
diff changeset
94 fprintf(stderr, "-J is reserved for Jython\n");
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
95 return '_';
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
96 }
46406
c1fa2e758e05 Applied patch #2617 from Frank Wierzbicki wit some extras from me
Christian Heimes <christian@cheimes.de>
parents: 39073
diff changeset
97
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
98 if (option == 'X') {
80503
d2df83d7c649 #16306: Fix multiple error messages when unknown command line parameters where passed to the interpreter. Patch by Hieu Nguyen.
Ezio Melotti <ezio.melotti@gmail.com>
parents: 75147
diff changeset
99 if (_PyOS_opterr)
d2df83d7c649 #16306: Fix multiple error messages when unknown command line parameters where passed to the interpreter. Patch by Hieu Nguyen.
Ezio Melotti <ezio.melotti@gmail.com>
parents: 75147
diff changeset
100 fprintf(stderr,
d2df83d7c649 #16306: Fix multiple error messages when unknown command line parameters where passed to the interpreter. Patch by Hieu Nguyen.
Ezio Melotti <ezio.melotti@gmail.com>
parents: 75147
diff changeset
101 "-X is reserved for implementation-specific arguments\n");
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
102 return '_';
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
103 }
46406
c1fa2e758e05 Applied patch #2617 from Frank Wierzbicki wit some extras from me
Christian Heimes <christian@cheimes.de>
parents: 39073
diff changeset
104
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
105 if ((ptr = strchr(optstring, option)) == NULL) {
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
106 if (_PyOS_opterr)
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
107 fprintf(stderr, "Unknown option: -%c\n", option);
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
108
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
109 return '_';
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
110 }
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
111
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
112 if (*(ptr + 1) == ':') {
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
113 if (*opt_ptr != '\0') {
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
114 _PyOS_optarg = opt_ptr;
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
115 opt_ptr = "";
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
116 }
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
117
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
118 else {
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
119 if (_PyOS_optind >= argc) {
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
120 if (_PyOS_opterr)
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
121 fprintf(stderr,
80503
d2df83d7c649 #16306: Fix multiple error messages when unknown command line parameters where passed to the interpreter. Patch by Hieu Nguyen.
Ezio Melotti <ezio.melotti@gmail.com>
parents: 75147
diff changeset
122 "Argument expected for the -%c option\n", option);
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
123 return '_';
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
124 }
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
125
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
126 _PyOS_optarg = argv[_PyOS_optind++];
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
127 }
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
128 }
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
129
61463
fd25030223b0 Untabify C files. Will watch buildbots.
Antoine Pitrou <solipsis@pitrou.net>
parents: 46435
diff changeset
130 return option;
1585
7c75f60468f8 A getopt.c for your amusement
Guido van Rossum <guido@python.org>
parents:
diff changeset
131 }
37655
2f3f2e32dfd9 spread the extern "C" { } magic pixie dust around. Python itself builds now
Anthony Baxter <anthonybaxter@gmail.com>
parents: 15374
diff changeset
132
2f3f2e32dfd9 spread the extern "C" { } magic pixie dust around. Python itself builds now
Anthony Baxter <anthonybaxter@gmail.com>
parents: 15374
diff changeset
133 #ifdef __cplusplus
2f3f2e32dfd9 spread the extern "C" { } magic pixie dust around. Python itself builds now
Anthony Baxter <anthonybaxter@gmail.com>
parents: 15374
diff changeset
134 }
2f3f2e32dfd9 spread the extern "C" { } magic pixie dust around. Python itself builds now
Anthony Baxter <anthonybaxter@gmail.com>
parents: 15374
diff changeset
135 #endif
2f3f2e32dfd9 spread the extern "C" { } magic pixie dust around. Python itself builds now
Anthony Baxter <anthonybaxter@gmail.com>
parents: 15374
diff changeset
136