Re: "Padding for future expansion"



On Mon, 2008-01-07 at 04:27 -0800, Micah Carrick wrote:
> When looking at some GTK widgets, you see things like...
> 
> void (*_gtk_reserved0) (void);
> 
> Why is it necessary to "reserve" the space for them? Why not just add 
> the functions when new versions come out?

because it would break the ABI, and applications compiled against an
older version of GTK+ would not be able to run with a newer one.

since GTK+ guarantees ABI as well as API compatibility for all the
releases with the same major number, the padding is necessary for all
the structures that can be expanded at later date.

ciao,
 Emmanuele.

-- 
Emmanuele Bassi,
W: http://www.emmanuelebassi.net
B: http://log.emmanuelebassi.net



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]