Hi, Since the creation of the GCC 4.0 branch back in February a number of minor C++ language changes seem to have slipped in. Let me mention just two examples:
1) With GCC 4.0.0 this code used to compile: 1 struct foo { 2 friend class bar; 3 void screw(bar&); 4 }; With GCC 4.0.1 it stopped compiling. From a language lawyer point of view this is okay, since a friend declaration is not a declaration. 2) With GCC 4.0.1 this code used to compile: 1 struct lala { 2 void f() const {} 3 }; 4 struct lulu { 5 template<class T> lulu(void (T::*)()) {} 6 }; 7 lulu froobrazzz(&lala::f); With current GCC 4.0 snapshot (4.0.2 20050901) it doesn't compile. Again, the code was probably broken to begin with because the member function argument in line 7 is a const member function for which the parameter in the lulu ctor is not a match. Are you really, really sure such language tightening is appropiate for bug-fix releases? (Note that the examples above are not regressions since gcc-3.4.y accept both of them.) This lead to developer irritation because people expect that what compiled with GCC x.y.z should still compile with GCC x.y.z+1. At least, that used to be my reading of the GCC Development Plan [0]. What makes things really annoying is that some distributions use the latest snapshot from the branch for their toolchain [1] (Hi Matthias!). This results in packages suddenly refusing to build. Then, the upstream maintainers get notified about this and are confused because it "works for them" and it must be the silly distribution's fault... Would it be insolent to ask you GCC developers to, please, refrain from making pedantic changes to the language from GCC x.y.z to x.y.z+1 and keep such changes for the major releases? Cheers -richy. (putting his asbestos suit on) PS: Frankly, I've no idea what patches broke the two examples above. If the breaking couldn't be avoided because something else had to be fixed, then forget this email. [0] <http://gcc.gnu.org/develop.html> [1] I don't talk about distros that use the latest version from HEAD. Screw them! -- Richard B. Kreckel <http://www.ginac.de/~kreckel/>