[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: svn commit: r27807 - trunk/subversion/mod_dav_svn

From: Lieven Govaerts <svnlgo_at_mobsol.be>
Date: 2007-11-14 08:59:34 CET

Kamesh Jayachandran wrote:
> Will it work on all compilers? I mean 'declaration after a function
> call' rule.
>

It's ok here, because that function call is just used to initialize the
newly declared variable.

You can't add a declaration after a statement in C89, but a variable
declaration can include an initialization (like in this example).

Lieven

> dlr@tigris.org wrote:
>> Author: dlr
>> Date: Tue Nov 13 21:28:52 2007
>> New Revision: 27807
>>
>> Log:
>> Stylistic tweak.
>>
>> * subversion/mod_dav_svn/repos.c
>> (capabilities_as_list): Swap order of local variable declaration.
>>
>>
>> Modified:
>> trunk/subversion/mod_dav_svn/repos.c
>>
>> Modified: trunk/subversion/mod_dav_svn/repos.c
>> URL:
>> http://svn.collab.net/viewvc/svn/trunk/subversion/mod_dav_svn/repos.c?pathrev=27807&r1=27806&r2=27807
>>
>> ==============================================================================
>>
>> --- trunk/subversion/mod_dav_svn/repos.c (original)
>> +++ trunk/subversion/mod_dav_svn/repos.c Tue Nov 13 21:28:52 2007
>> @@ -1441,9 +1441,9 @@
>> static apr_array_header_t *
>> capabilities_as_list(apr_hash_t *capabilities, apr_pool_t *pool)
>> {
>> - apr_hash_index_t *hi;
>> apr_array_header_t *list = apr_array_make(pool,
>> apr_hash_count(capabilities),
>> sizeof(char *));
>> + apr_hash_index_t *hi;
>>
>> for (hi = apr_hash_first(pool, capabilities); hi; hi =
>> apr_hash_next(hi))
>> {
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: svn-unsubscribe@subversion.tigris.org
>> For additional commands, e-mail: svn-help@subversion.tigris.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: dev-help@subversion.tigris.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Nov 14 08:59:44 2007

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.