You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Julian Foad <ju...@btopenworld.com> on 2009/09/30 16:48:48 UTC

Re: WC-NG question: ctx->wc_ctx docs

On Tue, 2009-07-28 at 19:58 -0500, Hyrum K. Wright wrote:
> On Jul 28, 2009, at 1:10 PM, C. Michael Pilato wrote:
> 
> > Reading in svn_client.h, I see:
> >
> >  /** An optional working copy context for the client operation to use.
> >   * This is initialized by svn_client_create_context() and should  
> > never
> >   * be @c NULL.
> >   *
> >   * @since New in 1.7.  */
> >  svn_wc_context_t *wc_ctx;
> >
> > Can someone help me interpret this?  If the wc_ctx pointer is  
> > "optional",
> > then what (if not NULL) is its value when the structure initializer  
> > "opts
> > out" on this field?
> 
> Yeah, something there doesn't parse quite right.  Here's the skinny:
> 
> 1.7-era libsvn_client will initialize the value, and since it's  
> assumed that the same version of the library which initialized it will  
> always be using it, all 1.7-era APIs also assume it is non-NULL.   
> Previous versions of the library obviously have no notion of wc_ctx,  
> will not initialize the value (heck, won't even allocate memory for  
> it), and won't ever use it.
> 
> So the docstring should probably be updated to say something like  
> "this always get initialized inside of svn_client_create_context()".

I removed the word "optional" in r39712.

- Julian

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=2402175