From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1K3e3S-0004jJ-4b for qemu-devel@nongnu.org; Tue, 03 Jun 2008 17:28:30 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1K3e3R-0004gg-Dt for qemu-devel@nongnu.org; Tue, 03 Jun 2008 17:28:29 -0400 Received: from [199.232.76.173] (port=56615 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1K3e3Q-0004g6-V0 for qemu-devel@nongnu.org; Tue, 03 Jun 2008 17:28:28 -0400 Received: from an-out-0708.google.com ([209.85.132.251]:6048) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1K3e3Q-0002eB-Jw for qemu-devel@nongnu.org; Tue, 03 Jun 2008 17:28:28 -0400 Received: by an-out-0708.google.com with SMTP id d18so671225and.130 for ; Tue, 03 Jun 2008 14:28:28 -0700 (PDT) Message-ID: <4845B76F.3010209@codemonkey.ws> Date: Tue, 03 Jun 2008 16:28:15 -0500 From: Anthony Liguori MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH] New qemu-img convert -B option to preserve the COW aspect of images and/or re-base them References: <48459641.5040000@codemonkey.ws> <20080603194041.GE6899@shareable.org> <4845A5C4.6050309@codemonkey.ws> <20080603204313.GA9995@shareable.org> In-Reply-To: <20080603204313.GA9995@shareable.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Jamie Lokier wrote: > Anthony Liguori wrote: > >> It's sloppy. In general, using a non-portable feature for no good >> reason other than you can is bad practice (even if we do depend on GCC). >> > > It's 2008, the standard is called C99 for a reason. > Regardless, it's sloppy IMHO. It's a lot easier to determine the type of something by looking at the top of the block. And this is the convention for a very lot of projects Open Source projects, even the ones that heavily rely on GCC-isms like the Linux kernel. Regards, Anthony Liguori > In 1998, we would have used C89 constructs like function prototypes, > wouldn't we? > > :-) > > If you don't want to use non-portable features, may I suggest > "gcc -std=c89". > > (Half joking, I use -Wdeclaration-after-statement myself to catch > this, since it became a standard GCC feature with no option to turn it > off and keep other GNU extensions. But then, I write code which is > more portable than QEMU and target older architectures.) > > -- Jamie > > >