git: 9front

Download patch

ref: 40c06324b43ef895fab3223609473be03d30f5c3
parent: eea0c17049ce5cb0d71856d7e7a937823fab216f
author: Sigrid Solveig Haflínudóttir <sigrid@ftrv.se>
date: Mon Mar 20 09:08:31 EDT 2023

cc: fndecls: always ignore non-function types

--- a/sys/src/cmd/cc/dcl.c
+++ b/sys/src/cmd/cc/dcl.c
@@ -737,6 +737,8 @@
 	static Sym *funcsym;
 	Node *n;
 
+	if(thisfnnode->etype != TFUNC)
+		return;
 	if(pass == 0){
 		n = new(ONAME, Z, Z);
 		n->type = typ(TARRAY, garbt(types[TCHAR], BCONSTNT));
--