Date: Mon, 01 Aug 2016 01:23:10 +0000 From: bugzilla-noreply@freebsd.org To: freebsd-ports-bugs@FreeBSD.org Subject: [Bug 211305] devel/gdb: (CORE_ADDR) 0 missing * in cast in tui/tui-stack.c Message-ID: <bug-211305-13-nxWaDgKDP1@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-211305-13@https.bugs.freebsd.org/bugzilla/> References: <bug-211305-13@https.bugs.freebsd.org/bugzilla/>
next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D211305 --- Comment #9 from Mark Millard <markmi@dsl-only.net> --- (In reply to Mark Millard from comment #5) For: msp430-tdep.c:401:24: warning: comparison of constant 16 with expression of type 'MSP430_Size' is always false [-Wtautological-constant-out-of-range-compare] int size =3D opc.size =3D=3D 16 ? 2 : 4; ~~~~~~~~ ^ ~~ Things are odd: /include/opcode/msp430-decode.h has: typedef enum { MSP430_Byte =3D 0, MSP430_Word, MSP430_Addr } MSP430_Size; . . . typedef struct { . . . MSP430_Size size; /* Operand size in BITS. */ . . . } MSP430_Opcode_Decoded; While gdb/msp430-tdep.c has: MSP430_Opcode_Decoded opc; So if the code generation matches the warning: int size =3D opc.size =3D=3D 16 ? 2 : 4; would turn into int size =3D 4; Adding a MSP430_Size name for the value 16 likely would avoid the warning or any odd optimization even if the symbolic name is not otherwise used. (I've just assumed that the 16 is appropriate.) --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-211305-13-nxWaDgKDP1>