From owner-freebsd-current@FreeBSD.ORG Sat Feb 14 14:16:37 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DA97516A4CE for ; Sat, 14 Feb 2004 14:16:37 -0800 (PST) Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3D77743D1D for ; Sat, 14 Feb 2004 14:16:37 -0800 (PST) (envelope-from phk@phk.freebsd.dk) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.12.10/8.12.10) with ESMTP id i1EMGYhM008833 for ; Sat, 14 Feb 2004 23:16:35 +0100 (CET) (envelope-from phk@phk.freebsd.dk) To: current@freebsd.org From: Poul-Henning Kamp Date: Sat, 14 Feb 2004 23:16:34 +0100 Message-ID: <8832.1076796994@critter.freebsd.dk> Subject: GCC bug ? X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 14 Feb 2004 22:16:38 -0000 This seems wrong to me, GCC should warn about the double initialization. critter phk> cat a.c struct foo { int bar; int barf; }; struct foo myfoo = { .bar = 1, .bar = 2, }; critter phk> cc -Wall -c a.c critter phk> -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence.