shithub: scc

Download patch

ref: b4b8c8c5ff06d158b4aaa3811bcb39ce2a7c07e8
parent: 7c7fb51c9d0b8fd7f3497d87d6425eb9a9037e3d
author: Roberto E. Vargas Caballero <k0ga@shike2.com>
date: Sun Jul 13 02:54:36 EDT 2014

Remove qualifer stuff from declarator0()

This stuff is not going to be used anymore.

--- a/cc1/decl.c
+++ b/cc1/decl.c
@@ -124,36 +124,23 @@
 static struct dcldata*
 declarator0(struct dcldata *dp, int8_t flags)
 {
-	uint8_t buffer[NR_DECLARATORS];
-	register uint8_t *bp, n, qlf;
+	register uint8_t  n;
 
-	bp = buffer;
 	for (n = 0; accept('*'); ++n) {
-		if (n == NR_DECLARATORS)
-			goto too_much_declarators;
-		qlf = 0;
-		if (yytoken == TQUALIFIER) {
-			qlf |= yylval.token;
-			next();
-		}
-		*bp++ = qlf;
+		while (accept(TQUALIFIER))
+			/* nothing */;
 	}
 
 	dp = directdcl(dp, flags);
 
-	bp = buffer;
 	while (n--) {
 		if (dp->op == 255)
-			goto too_much_declarators;
+			error("too much declarators");
 		dp->op = PTR;
-		dp->u.qlf = *bp++;
 		++dp;
 	}
 
 	return dp;
-
-too_much_declarators:
-	error("too much declarators");
 }
 
 static Symbol *
--