From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:55015) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RyiEL-0000X6-MZ for qemu-devel@nongnu.org; Sat, 18 Feb 2012 06:13:30 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RyiEK-0005p8-9u for qemu-devel@nongnu.org; Sat, 18 Feb 2012 06:13:29 -0500 Received: from v220110690675601.yourvserver.net ([78.47.199.172]:50874) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RyiEK-0005p3-3K for qemu-devel@nongnu.org; Sat, 18 Feb 2012 06:13:28 -0500 Message-ID: <4F3F87D6.4050900@weilnetz.de> Date: Sat, 18 Feb 2012 12:13:26 +0100 From: Stefan Weil MIME-Version: 1.0 References: <1329556054-3601-1-git-send-email-sw@weilnetz.de> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] astyle: Formatting rules for QEMU List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Blue Swirl Cc: qemu-devel@nongnu.org Am 18.02.2012 11:10, schrieb Blue Swirl: > There are still indentation problems when expressions continue to next > line, also this does not look OK: > --- a/target-sparc/translate.c > +++ b/target-sparc/translate.c > @@ -36,7 +36,7 @@ > > #define DYNAMIC_PC 1 /* dynamic pc value */ > #define JUMP_PC 2 /* dynamic pc value which takes only two values > - according to jump_pc[T2] */ > +according to jump_pc[T2] */ Writing comments like this looks nice, but needs more work when the comments are written. Maintenance of the code is also more difficult: any time a new line with a longer name is added, you have to reformat all other lines to preserve the good look. Just add this line to the code given above to see what I mean: #define ANY_LONG_PC 3 /* just an example */ This is why I usually write comments in an extra line before the code statement. Regards, Stefan