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

Re: [PATCH] Python bindings for svn.ra.get_commit_editor2()

From: David James <djames_at_collab.net>
Date: 2006-05-18 22:36:20 CEST

On 5/18/06, Jelmer Vernooij <jelmer@samba.org> wrote:
> The attached patch fixes the arguments of the Python bindings for the
> svn.ra.get_commit_editor2() call. Typemaps for the return value
> (svn_delta_editor *, void *) will be the next patch.
>
> [[[
> * subversion/bindings/swig/svn_delta.i: Remove duplicate prototype for
> svn_swig_py_make_editor
>
> * subversion/bindings/swig/svn_ra.i: Mark const svn_delta_editor ** as
> out argument
>
> * subversion/bindings/swig/python/tests/ra.py: Add test for
> svn.ra.get_commit_editor2()
>
> * subversion/bindings/swig/include/svn_types.swg
> subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h
> subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c
> (svn_swig_py_commit_callback2): Add Python wrapper for
> svn_commit_callback2_t()
> ]]]

Thanks Jelmer! Great patch. I committed it in r19718. Before
committing, I noticed and fixed three minor problems:
  1. The prototype for svn_swig_py_make_editor in svn_delta.i is not a
duplicate prototype; it is needed so that SWIG will know to wrap the
function. So I updated your patch to not remove this prototype.
(Without this fix, make check-swig-py fails.)
  2. There's a few stray tabs in swigutil_py.c. (Can you fix your
editor settings so that your editor does not add tabs?)
  3. The log message should start with a general description of what
you are trying to do. Please see my example below.

[[[
Create typemaps for the input arguments of svn.ra.get_commit_editor2().

TODO: Add typemaps for the return value of this function as well.

Patch by: Jelmer Vernooij <jelmer@samba.org>
          me

* subversion/bindings/swig/svn_ra.i:
  Mark const svn_delta_editor ** as out argument

* subversion/bindings/swig/python/tests/ra.py:
  (test_commit): Add test for svn.ra.get_commit_editor2()

* subversion/bindings/swig/include/svn_types.swg
  subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h
  subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c
  (svn_swig_py_commit_callback2): Add Python wrapper for
   svn_commit_callback2_t()
]]]

Cheers,

David

-- 
David James -- http://www.cs.toronto.edu/~james
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu May 18 22:36:45 2006

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.