Re: [pygccxml-development] mdecl and methods that return values
Brought to you by:
mbaas,
roman_yakovenko
|
From: Roman Y. <rom...@gm...> - 2006-05-30 05:12:14
|
On 5/30/06, Allen Bierbaum <al...@vr...> wrote:
> I just ran into an interesting limitation on the current API.
>
> Namely, when you call methods on mdecl_wrappers and those methods return
> decls for further processing, the return values are ignored.
>
> I ran into in the following case:
>
> my_class = my_namespace["MyClass"]
> my_class["mymethod"].exclude()
exclude does not have return value
> It could also come up in something else like this though:
>
> similar_classes = my_namespace.classes(re_matcher(".*Proxies"))
> similar_classes.member_functions["bad_function"].exclude()
>
> The point is that that the call_redirector_t for mdecl_wrapper doesn't
> return any values from the methods it calls.
>
> I propose that we refactor this method to build up a list of decls
> returned from all the calls it makes and return them wrapped as a
> mdecl_wrapper_t if there are values returned and if they make sense to
> combine (ie. if they are all decl wrappers). This should allow
> functionality like above and would add quite a bit of flexibility to
> finding groups of matches within other groups of matches. (ex: find
> groups of similar methods inside groups of similar classes)
> Any comments?
Allen, I am sorry but I don't understand you. Do you want to know what
declarations
has been [in|ex]cluded? Or you want something more general: to define
return values
for mdecl_wrapper_t for "get" and "call" functionality, as a list of
returned values?
Also, can you modify mdec_wrapper.py file and send it?
Thanks
--
Roman Yakovenko
C++ Python language binding
http://www.language-binding.net/
|