Re: Return type of vfuncs
- From: Marko Anastasov <marko marko anastasov name>
- To: Johannes Schmid <johannes schmid gmx de>
- Cc: GTKmm List <gtkmm-list gnome org>
- Subject: Re: Return type of vfuncs
- Date: Fri, 13 Oct 2006 01:27:07 +0200
On Thu, 2006-10-12 at 23:48 +0200, Johannes Schmid wrote:
> Hi!
>
> While I tried to complete libanjutamm I ran into the following problem.
> gmmproc generates this for a vfunc return a Glib::ListHandle:
>
> (...)
> typedef Glib::ListHandle<Editor*> RType;
> return RType();
> }
>
> The bad thing is, that Glib::ListHandle does not have a constructor with
> zero arguments so this will never work! The line to generate the vfunc
> is the following:
>
> _WRAP_VFUNC(Glib::ListHandle<Editor*> get_editors ( GError** err),
> "get_editors")
>
> How is this supposed to work or am I totally wrong?
I suppose you could _IGNORE(get_editors), declare a virtual function
manually in the *.hg file and implement it in *.ccg where you would
call ListHandle constructor with the GList as a parameter.
Btw why GErrors and not exceptions? (Sorry if this is a decision
I missed earlier.)
Marko
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]