Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: "type punned" warnings



Peter Stephenson wrote:
> gcc -c -I. -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64  -DHAVE_CONFIG_H -O2 -W
> all -Wno-implicit -Wmissing-prototypes -ggdb  -o builtin.o builtin.c
> builtin.c: In function  `typeset_single':
> builtin.c:2145: error:  `struct param' has no member named `flags'
> builtin.c:2145: error:  `struct param' has no member named `flags'

It was just in a single DPUTS().

Index: Src/builtin.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/builtin.c,v
retrieving revision 1.155
diff -u -r1.155 builtin.c
--- Src/builtin.c	7 Mar 2006 21:30:36 -0000	1.155
+++ Src/builtin.c	8 Mar 2006 15:46:52 -0000
@@ -2142,7 +2142,7 @@
 	if (!(pm = setsparam(pname, ztrdup(value))))
 	    return NULL;
 	if (pm != ipm) {
-	    DPUTS(ipm->flags != pm->flags,
+	    DPUTS(ipm->node.flags != pm->node.flags,
 		  "BUG: parameter recreated with wrong flags");
 	    unsetparam_pm(ipm, 0, 1);
 	}

-- 
Peter Stephenson <pws@xxxxxxx>                  Software Engineer
CSR PLC, Churchill House, Cambridge Business Park, Cowley Road
Cambridge, CB4 0WZ, UK                          Tel: +44 (0)1223 692070


To access the latest news from CSR copy this link into a web browser:  http://www.csr.com/email_sig.php



Messages sorted by: Reverse Date, Date, Thread, Author