shithub: scc

Download patch

ref: e288e44926d1cb8f0f7c3b837466698007a95c5d
parent: fb10d4864465bf9398705011026ff12cd19da2a6
author: Roberto E. Vargas Caballero <[email protected]>
date: Thu Oct 31 15:20:47 EDT 2013

Fix declaration of typedef variables

Variables with a type derivated from a typedef can also
have storage and qualifier specifiers, so the restriction
was too much restrictive.

--- a/decl.c
+++ b/decl.c
@@ -205,7 +205,7 @@
 			next();
 			return structdcl(tp);
 		case IDEN:
-			if (!tp->defined && !store->defined && !qlf->defined) {
+			if (!tp->defined) {
 				register struct symbol *sym;
 
 				sym = lookup(yytext, NS_IDEN);