Date: Sat, 3 Feb 1996 13:54:17 -0700 From: smp@csn.net To: FreeBSD-gnats-submit@freebsd.org Subject: bin/993: noise from g++ & cpufunc.h Message-ID: <199602032054.NAA27872@ilsa.systemsix.com> Resent-Message-ID: <199602032100.NAA29288@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 993 >Category: bin >Synopsis: g++ complains about /usr/include/machine/cpufunc.h >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-bugs >State: open >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sat Feb 3 13:00:02 PST 1996 >Last-Modified: >Originator: Steve Passe >Organization: New Ideas >Release: FreeBSD 2.1-STABLE i386 >Environment: g++ >Description: cpufunc.h has 2 lines that generate 'noise' on every compile: /usr/include/machine/cpufunc.h: In function `void insque(void *, void *)': In file included from ds1820.c:23: /usr/include/machine/cpufunc.h:310: warning: ANSI C++ forbids implicit conversion from `void *' in initialization /usr/include/machine/cpufunc.h:310: warning: ANSI C++ forbids implicit conversion from `void *' in initialization /usr/include/machine/cpufunc.h: In function `void remque(void *)': /usr/include/machine/cpufunc.h:321: warning: ANSI C++ forbids implicit conversion from `void *' in initialization >How-To-Repeat: compile a program with g++ that includes /usr/include/machine/cpufunc.h >Fix: apply the following patch to /usr/include/machine/cpufunc.h: *** cpufunc.h.orig Sat Feb 3 13:45:14 1996 --- cpufunc.h Sat Feb 3 13:48:33 1996 *************** *** 307,313 **** static __inline void insque(void *a, void *b) { ! struct quehead *element = a, *head = b; element->qh_link = head->qh_link; element->qh_rlink = head; --- 307,314 ---- static __inline void insque(void *a, void *b) { ! struct quehead *element = ! (struct quehead*)a, *head = (struct quehead*)b; element->qh_link = head->qh_link; element->qh_rlink = head; *************** *** 318,324 **** static __inline void remque(void *a) { ! struct quehead *element = a; element->qh_link->qh_rlink = element->qh_rlink; element->qh_rlink->qh_link = element->qh_link; --- 319,325 ---- static __inline void remque(void *a) { ! struct quehead *element = (struct quehead *)a; element->qh_link->qh_rlink = element->qh_rlink; element->qh_rlink->qh_link = element->qh_link; >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199602032054.NAA27872>