shithub: scc

Download patch

ref: a13c8cf6f4209b766a9491c57179647762756c19
parent: 2d30362df693b46f67f1515e9d23e56e237410a5
author: Roberto E. Vargas Caballero <[email protected]>
date: Thu Apr 10 03:30:29 EDT 2014

Small type changes

struct node is deprecated, use Node. Put the register word
is funny, so use it.

--- a/expr.c
+++ b/expr.c
@@ -195,7 +195,7 @@
 static Node *
 postfix(void)
 {
-	Node *np1, *np2;
+	register Node *np1, *np2;
 
 	np1 = primary();
 	for (;;) {
@@ -219,7 +219,7 @@
 static Node *
 unary(void)
 {
-	Node *np;
+	register Node *np;
 
 	switch (yytoken) {
 	case INC: case DEC:
@@ -231,11 +231,11 @@
 	}
 }
 
-static struct node *
+static Node *
 cast(void)
 {
 	Type *tp;
-	Node *np1, *np2;
+	register Node *np1, *np2;
 	extern Type *typename(void);
 
 	if (yytoken == '(') {
@@ -256,7 +256,7 @@
 	return unary();
 }
 
-static struct node *
+static Node *
 mul(void)
 {
 	register Node *np;
@@ -275,7 +275,7 @@
 	}
 }
 
-static struct node *
+static Node *
 add(void)
 {
 	register char op;