Re: [PATCH 1/2] remove space between function name and (

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2011/2/18 Eric Blake <eblake@xxxxxxxxxx>:
> On 02/17/2011 02:18 PM, Christophe Fergeau wrote:
>> There were several occurrences of an extra space inserted between
>> a function name and the ( opening the argument list in
>> datatypes.c. This is not consistent with the coding style used in
>> the rest of this file so removing this extra space makes the
>> code slightly more readable.
>> ---
>> Âsrc/datatypes.c | Â 14 +++++++-------
>> Â1 files changed, 7 insertions(+), 7 deletions(-)
>>
>> diff --git a/src/datatypes.c b/src/datatypes.c
>> index 7cc37c1..1b68f6a 100644
>> --- a/src/datatypes.c
>> +++ b/src/datatypes.c
>> @@ -243,19 +243,19 @@ virReleaseConnect(virConnectPtr conn) {
>> Â Â ÂvirMutexUnlock(&conn->lock);
>>
>> Â Â Âif (conn->networkDriver)
>> - Â Â Â Âconn->networkDriver->close (conn);
>> + Â Â Â Âconn->networkDriver->close(conn);
>
> ACK and pushed.
>
> In the past, there has been talk about running the entire code base
> through a formatting tool, but we haven't yet found one that quite
> matches existing coding style, so it has been a series of manually
> touching up inconsistencies while in the area.
>

I tried to use uncrustify [1]. It has tones of options to configure
the style. I tweaked it's default config file to match libvirt's
style. Works quite well, but there are still some issues left with how
it breaks certain long functions calls and if statements.

I attached my config so you can give it a try if you like :)

[1] http://uncrustify.sourceforge.net/

Attachment: uncrustify.cfg
Description: Binary data

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]