Re: C99 Initialisers

From: Greg KH
Date: Tue Aug 12 2003 - 19:29:55 EST


On Wed, Aug 13, 2003 at 01:08:41AM +0100, Matthew Wilcox wrote:
> On Wed, Aug 13, 2003 at 12:53:24AM +0100, Dave Jones wrote:
> > What would be *really* nice, would be the ability to do something
> > to the effect of..

Yeah, that would be cool to do. 2.7 :)

> While we're off in never-never land, it'd be nice to specify default
> values for struct initialisers. eg, something like:

Yeah, I've wanted that for a while too. Don't really know how to get
the compiler to do that though :(

> Erm, hang on a second ... Since when are PCI IDs 32-bit? What is this
> ridiculous bloat? You can't even argue that this makes things pack
> better since this packs equally well:

Yeah, it was just a port from 2.4 which says:

struct pci_device_id {
unsigned int vendor, device;
unsigned int subvendor, subdevice;
unsigned int class, class_mask;
unsigned long driver_data;
};

We could probably change it now if you really want to. Don't know if it
will save much space though.

thanks,

greg k-h
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/