Re: RE : a simple list

2006-05-09 Thread vincent guffens
Eric Salomé wrote: > Hi Vincent, > > I picked up your email from the archive as I didn't received it yet. > > As you see, it's very easy with a simple #define to create simple code > for simple cases and yet be powerful for more complex cases : > #define grub_iterate_list_brk(list, func, context,

Re: RE : a simple list

2006-05-09 Thread vincent guffens
Thank you for this information. Adding the concept of context is indeed the right idea. I was doing it as follows void function (grub_device_t dev) { grub_device_t it; auto int look_for_dev (grub_device_t); int look_for_dev (grub_device_t grub_device_t other_dev) { return compare (dev,