I fixed this; but first, I added -Wdeclaration-after-statement in
maintainer mode, and yes, it catches this class of problems. Of course,
currently it's quite useless with all the deprecation warnings; but it
should be there.
-- Brane
Edmund Wong wrote:
> Neels Janosch Hofmeyr wrote:
>
>> Author: neels
>> Date: Sun Nov 8 13:40:39 2009
>> New Revision: 40424
>>
>>
>
>
>> +static svn_error_t*
>> +get_node_uri(svn_revnum_t *revision,
>> + const char **repos_relpath,
>> + const char **repos_root_url,
>> + svn_wc__db_t *db,
>> + const char *local_abspath,
>> + apr_pool_t *result_pool,
>> + apr_pool_t *scratch_pool)
>> +{
>> + svn_error_t *err;
>> + *revision = SVN_INVALID_REVNUM;
>> + svn_boolean_t do_scan = FALSE;
>> +
>>
>
> Hi Neels,
>
> For some reasons, under VS2008, it's complaining about this last line
> with the following errors:
>
>
> ..\..\..\subversion\libsvn_wc\update_editor.c(1632): error C2275:
> 'svn_boolean_t' : illegal use of this type as an expression
> ..\..\..\subversion\libsvn_wc\update_editor.c(1632): error C2146: syntax
> error: missing ';' before identifier 'do_scan'
> ..\..\..\subversion\libsvn_wc\update_editor.c(1632): error C2065:
> 'do_scan' : undeclared identifier
> ..\..\..\subversion\libsvn_wc\update_editor.c(1651): error C2065:
> 'do_scan' : undeclared identifier
> ..\..\..\subversion\libsvn_wc\update_editor.c(1656): error C2065:
> 'do_scan' : undeclared identifier
>
> I don't understand this at all. Switching the last two statements
> to the following fixes this 'problem' (but still leaves me wondering
> what was wrong with it in the first place'.
>
> > + svn_error_t *err;
> > + svn_boolean_t do_scan = FALSE;
> > + *revision = SVN_INVALID_REVNUM;
>
> I was thinking of doing a patch; but, since I have no understanding
> of WHY it doesn't complain here whereas it complains with the
> initial code, I decided to forgo the patch and see if anyone
> here can explain it.
>
> Edmund
>
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=2415665
Received on 2009-11-09 04:30:10 CET