[ccan] Question on list module

Rusty Russell rusty at rustcorp.com.au
Tue Dec 14 16:51:56 EST 2010


On Tue, 14 Dec 2010 10:21:44 am richard -rw- weinberger wrote:
> Hello Dave, Kim,
> 
> On Tue, Dec 14, 2010 at 12:40 AM, David Collett <david.collett at gmail.com> wrote:
> > Hi Richard,
> >
> > If you require your object to belong to multiple lists *at the same
> > time*, you need to include a list_node in your object for each list
> > you wish to belong to, just give them different (e.g. descriptive)
> > names.
> 
> Thats what i thought. :-(
> I don't know in how many lists a object exists.
> It depends on runtime information.
> 
> I'll refactor my program.
> Anyway, thanks for your answers!

Ah, if you want *external* lists, you'll need to come up with something.
Either a struct with a list_node and a pointer, or perhaps use a jmap
if that fits better...

Cheers,
Rusty.
PS.  An external list module might be worthwhile :)


More information about the ccan mailing list