summaryrefslogtreecommitdiffstats
path: root/Parser/listnode.c
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1990-12-20 15:06:42 (GMT)
committerGuido van Rossum <guido@python.org>1990-12-20 15:06:42 (GMT)
commit3f5da24ea304e674a9abbdcffc4d671e32aa70f1 (patch)
treee932e31cb9381f40b7c87c377638216c043b5cfc /Parser/listnode.c
parent226d79eb4a776dd54c9e4544b17deaf928bcef3a (diff)
downloadcpython-3f5da24ea304e674a9abbdcffc4d671e32aa70f1.zip
cpython-3f5da24ea304e674a9abbdcffc4d671e32aa70f1.tar.gz
cpython-3f5da24ea304e674a9abbdcffc4d671e32aa70f1.tar.bz2
"Compiling" version
Diffstat (limited to 'Parser/listnode.c')
-rw-r--r--Parser/listnode.c41
1 files changed, 21 insertions, 20 deletions
diff --git a/Parser/listnode.c b/Parser/listnode.c
index e0a979e..9d24c0f 100644
--- a/Parser/listnode.c
+++ b/Parser/listnode.c
@@ -1,13 +1,31 @@
/* List a node on a file */
-#include <stdio.h>
-
-#include "PROTO.h"
+#include "pgenheaders.h"
#include "token.h"
#include "node.h"
+/* Forward */
+static void list1node PROTO((FILE *, node *));
+
+void
+listtree(n)
+ node *n;
+{
+ listnode(stdout, n);
+}
+
static int level, atbol;
+void
+listnode(fp, n)
+ FILE *fp;
+ node *n;
+{
+ level = 0;
+ atbol = 1;
+ list1node(fp, n);
+}
+
static void
list1node(fp, n)
FILE *fp;
@@ -49,20 +67,3 @@ list1node(fp, n)
else
fprintf(fp, "? ");
}
-
-void
-listnode(fp, n)
- FILE *fp;
- node *n;
-{
- level = 0;
- atbol = 1;
- list1node(fp, n);
-}
-
-void
-listtree(n)
- node *n;
-{
- listnode(stdout, n);
-}