This is the mail archive of the
guile@sourceware.cygnus.com
mailing list for the Guile project.
Re: Patch to make guile-gtk work with upcoming guile-1.4
- To: Mikael Djurfeldt <mdj at mdj dot nada dot kth dot se>
- Subject: Re: Patch to make guile-gtk work with upcoming guile-1.4
- From: "Greg J. Badros" <gjb at cs dot washington dot edu>
- Date: 19 Jun 2000 14:10:53 -0700
- Cc: Ariel Rios <ariel at arcavia dot com>, Marius Vollmer <mvo at dt dot e-technik dot uni-dortmund dot de>, guile at sourceware dot cygnus dot com, guile-gtk at sourceware dot cygnus dot com, djurfeldt at nada dot kth dot se
- References: <200006020301.WAA23978@erin.galway.com.mx> <qrr3dmawhl4.fsf@clavicle.cs.washington.edu> <xy766r69h0u.fsf@mdj.nada.kth.se>
Mikael Djurfeldt <mdj@mdj.nada.kth.se> writes:
> "Greg J. Badros" <gjb@cs.washington.edu> writes:
>
> > + tc16_gtkobj_marker_hook = scm_make_smob_type_mfpe("gtkobj_marker_hook",
> > + sizeof(sgtk_object_proxy),
> > + gtkobj_marker_hook,
> > + NULL,
> > + gtkobj_marker_hook_print,
> > + NULL);
>
> (Thanks to Greg for the patch.)
>
> Just a small comment:
>
> The `scm_make_smob_type_mfpe' function has not been mentioned in the
> NEWS file because it might become deprecated in next release of Guile.
I'd much prefer that this function not be depracated... notice all of
the redundancies and potential maintenance headaches below. People
*will* cut and paste from one section to another, change the *_hook in
the first line, and forget to change it in later lines, resulting in a
hard-to-find and nasty bug.
Greg
>
> Please instead use the standard interface:
>
> tc16_gtkobj_marker_hook = scm_make_smob_type ("gtkobj_marker_hook",
> sizeof (sgtk_object_proxy));
> scm_set_smob_mark (tc16_gtkobj_marker_hook, gtkobj_marker_hook);
> scm_set_smob_print (tc16_gtkobj_marker_hook, gtkobj_marker_hook_print);