LWN.net Logo

There is ONE exception

There is ONE exception

Posted Apr 3, 2009 13:06 UTC (Fri) by nix (subscriber, #2304)
In reply to: There is ONE exception by qg6te2
Parent article: A GNOME 3.0 plan

Actually, most of the stuff in that link is about not violating the
compiler's invariants regarding class definitions that change. As this is
technically a violation of the One Definition Rule in the C++ Standard,
it's unsurprising that it's a bit of a nest of snakes... but you come
across *exactly the same problem in C* if you have a system that makes
heavy use of structures and you want to change some of them without
recompiling all their users. The rules just *look* odder because the
structures are automatically built for you by the compiler: if you had to
build them by hand, *all the same issues would arise anyway*.


(Log in to post comments)

Copyright © 2012, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds