On Thu, 04 Nov 2004 21:13:33 -0600, Tim Ringenbach wrote
> >>One of my own suggestions was to make the giant struct of function
> >>pointers hidden and accessed through fuctions, at least by the
> >>prpls. That way changes to the prpl struct wouldn't break binary or
> >>source compatibility. Of course there would still be lots of other
> >>places to break compatibility, so it might not help much, but at
> >>least reording things wouldn't get function pointers set to the
> >>wrong members.
> >
> >The rendezvous PRPL does this in a way that avoids the reordering problem.
>
> I haven't looked at what rendezvous does.
>
> Ethan pointed out to me what I said above was bogus, and would cause
> the creation of lots of single use functions. He suggested instead
> passing a name, value list to a single function, e.g. { ...
> "add_buddy", oscar_add_buddy, .... }, or a hash table of string keys,
> function pointer value pairs. It would then by converted internally
> to a table, so it didn't need to be looked up each time.
>
> I probably should have just pasted the irc log, but I didn't log it.
>
> --Tim
No really, what's wrong with doing
prpl_info.list_icon = rendezvous_prpl_list_icon;
In the init_plugin() function of the PRPL?
-Mark
--
O O Mark Doliner
\ | mark@...
\ | http://www.kingant.net
"There needs to be a better word for weird."
|