Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!purdue!bu-cs!mirror!necntc!necis!mrst!sdti!wmm From: wmm@sdti.com (William M. Miller) Newsgroups: comp.lang.c++ Subject: Re: Should we use C++? Message-ID: <1989Oct19.025712.200@sdti.com> Date: 19 Oct 89 02:57:12 GMT References: <17898@rphroy.UUCP> Reply-To: wmm@sdti.SDTI.COM (William M. Miller) Organization: Software Development Technologies, Inc. Lines: 70 In article <17898@rphroy.UUCP> tkacik@rphroy.UUCP (Tom Tkacik) writes: >Is C++ ready for use yet? Yes, definitely. It has been used profitably in many situations already. Bjarne and company are *extremely* careful about the evolution of the language, and upward compatibility of existing code is one of the most important factors they consider. >I am questioning the stability of C++. How much further change will there be? There is a major change between 1.2 and 2.0. The most important features of that change were multiple inheritance, type-safe linkage, better control over storage allocation, and some new overloadable operators, although a number of other important things were also included. The current Zortech compiler is at a not-quite 1.2 level, although mostly compatible except for bugs; a 2.0 compiler is slated to be available on November 1. However, the only large areas of additional features currently anticipated as relatively near-term items are parameterized types (templates) and exception handling. The parameterized type design was published in the 1988 USENIX C++ Conference Proceedings, and while there has been no iron- clad guarantee that the final design will be identical in every respect, I believe it will be quite similar. The proposed exception handling mechanism will be the subject of a paper presented by Bjarne and Andy Koenig at the C++ at Work conference the first week of November, so nearly everything will be known in broad outline and in most significant details within a month. Another stabilizing factor (I hope!) is the formation of an ANSI standard C++ Committee. The organizational meeting of X3J16 will be held in Washington on December 5. The fact that the industry is willing to form a standard committee at this stage of C++'s development is, I think, a reflection of the belief that the language is relatively mature and will not continue evolving rapidly for very much longer. >Should we go ahead and use the C++ 1.2 that we got from our vendor? Yes. As I said, 2.0 is nearly completely upward compatible. Aside from a couple of minor items (e.g., the fact that the declaration of any class for which constant objects were created will have to be edited to declare constant member functions), mostly 1.2 code will be usable unchanged. You should *definitely* become familiar with the extensions of 2.0, however, so you don't inadvertantly do things the hard way without realizing that a better way is available in the new version. >Should we attempt to get the new version 2.0? Absolutely! Use of 1.2 should be viewed only as an interim step until you can get 2.0. Many of the grossities of 1.2 are eliminated or at least alleviated in 2.0. >Basically, 1) are the differences between the different current versions small >enough that code will be portable between them, and >2) will future changes to the language be small enough that we >will not have to change much of the code in the future? Answer to both questions: Yes, provided you keep your eyes open. In parti- cular, if you use g++, you *must* keep in mind what are nonstandard extensions in that environment because you won't find them anywhere else. John Carolan gave a pretty good talk on C++ programming for portability last February at Software Development '89; he might be willing to send you a set of the slides if you asked him (he's at Glockenspiel in Ireland; I don't have either the email or the regular mail address for them handy, but I'm sure someone does). -- Non-disclaimer: My boss and I always see eye-to-eye (every time I look in the mirror). ...!genrad!mrst!sdti!wmm