]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Changes for THINK C 4.0.
authorGuido van Rossum <guido@python.org>
Thu, 20 Dec 1990 23:13:00 +0000 (23:13 +0000)
committerGuido van Rossum <guido@python.org>
Thu, 20 Dec 1990 23:13:00 +0000 (23:13 +0000)
Include/pgenheaders.h
Parser/tokenizer.c

index 95fdbf21841761705a8536412e81a5b93fb8c11a..b53fdf276002be0842882525c8298b7ef7920d80 100644 (file)
@@ -2,13 +2,24 @@
    This is a precompiled header for THINK C. */
 
 #include <stdio.h>
+#include <string.h>
 
 #ifdef THINK_C
+/* #define THINK_C_3_0                 /*** TURN THIS ON FOR THINK C 3.0 ****/
 #define label label_
-#include <proto.h>
 #undef label
 #endif
 
+#ifdef THINK_C_3_0
+#include <proto.h>
+#endif
+
+#ifdef THINK_C
+#ifndef THINK_C_3_0
+#include <stdlib.h>
+#endif
+#endif
+
 #include "PROTO.h"
 #include "malloc.h"
 
index ad6f63ac02d6a129c215db9777ec51b7a72d7852..6bb57ef43ab3604fd5b5f7b70c73d4684305c84b 100644 (file)
@@ -358,8 +358,8 @@ tok_get(tok, p_start, p_end)
                   This is also recognized by vi, when it occurs near the
                   beginning or end of the file.  (Will vi never die...?) */
                int x;
-               /* XXX The case to (unsigned char *) is needed by THINK C */
-               if (sscanf((unsigned char *)tok->cur,
+               /* XXX The case to (unsigned char *) is needed by THINK C 3.0 */
+               if (sscanf(/*(unsigned char *)*/tok->cur,
                                " vi:set tabsize=%d:", &x) == 1 &&
                                                x >= 1 && x <= 40) {
                        fprintf(stderr, "# vi:set tabsize=%d:\n", x);