WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] [RFC] Coding style and standardisation

To: Mark Williamson <mark.williamson@xxxxxxxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: Re: [Xen-devel] [RFC] Coding style and standardisation
From: Keir Fraser <keir@xxxxxxxxxxxxx>
Date: Mon, 04 Jun 2007 10:24:36 +0100
Delivery-date: Mon, 04 Jun 2007 02:22:48 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <200706040603.45326.mark.williamson@xxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: Acemiir4aXxybRJ9EdyEowAX8io7RQ==
Thread-topic: [Xen-devel] [RFC] Coding style and standardisation
User-agent: Microsoft-Entourage/11.3.3.061214
On 4/6/07 06:03, "Mark Williamson" <mark.williamson@xxxxxxxxxxxx> wrote:

> Attached is a little extra documentation - my quick stab at summing up the Xen
> coding style.  I think the main points of difference from the Linux coding
> style are summarised here, but if anybody has anything else they think should
> be included (or anything they disagree with in my summary) it would be handy
> to know.

White space: only put spaces inside outermost brackets of if/while/for. For
example, "if ( (wibble & wombat) == 42 )".

Comments:
    /*
     * Multi-line comments are formatted like this.
     * No trailing white space, even at the end of the first line.
     */

Top-of-file comments: see e.g., common/page_alloc.c for preferred style.

Emacs style: it's okay to put an Emacs style block at the end of files,
e.g., as in common/page_alloc.c.

 -- Keir


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>