Re: contribute ctypeslib patch?

"Diez B. Roggisch" <[email protected]> Thu, 13 Aug 2015 12:31:42 +0200
Newsgroups gmane.comp.python.ctypes
Message-ID <[email protected]>
I wouldn’t say it’s dead - it is just extremely mature, and in the aspect you seem to care about, superseded by CFFI.

However, as it’s in the mainline Python distro, you should file your patch as a bug in python’s own bug-tracker IMHO.

HTH,

Diez


> On 13 Aug 2015, at 07:19, Jan Wagner <[email protected]> wrote:
> 
> Hi list,
> 
> it seems this project is quite dead and I'm not sure how to
> contribute a feature fix (not even to
> https://pypi.python.org/pypi/ctypeslib/ <https://pypi.python.org/pypi/ctypeslib/>). Perhaps someone on the
> list is able to do it?
> 
> There is an issue in ctypeslib codegenerator.py that affects
> xml2py.py option "-r" for which usage says that "-r EXPRESSION 
> regular expression for symbols to include". The expression is
> actually never evaluated as a regular expression. Only exact name
> matches are selected. The below patch changes the behaviour to be
> consistent with the usage instructions (and makes -r behaviour more
> useful).
> 
> cheers,
> Jan
> 
> ---
> /usr/lib/pymodules/python2.5/ctypeslib/codegen/codegenerator.py    
> 2009-01-17 03:50:18.000000000 +0900
> +++ codegenerator.py    2015-04-08 18:34:06.000000000 +0900
> @@ -859,6 +859,12 @@
>                  if match and match.group() == i.name:
>                      todo.append(i)
>                      break
> +               # above selects only *exact* matches, now include
> partial/regexp name matches:
> +               match = s.search(i.name)
> +               if match:
> +                    todo.append(i)
> +                    break
> +
>      if symbols or expressions:
>          items = todo
> 
> ------------------------------------------------------------------------------
> _______________________________________________
> ctypes-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/ctypes-users

------------------------------------------------------------------------------

_______________________________________________
ctypes-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ctypes-users