Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!elroy.jpl.nasa.gov!decwrl!ogicse!milton!blake.u.washington.edu!black From: black@blake.u.washington.edu (Jim Black) Newsgroups: comp.lang.c++ Subject: Re: Seeking critique(s) of C++ Message-ID: <18979@milton.u.washington.edu> Date: 24 Mar 91 22:29:59 GMT References: <1991Mar20.015750.9487@dbase.A-T.COM> <633@taumet.com> Sender: news@milton.u.washington.edu Organization: University of Washington, Seattle Lines: 29 I've been using C++ for a good while now, and I like it a lot more than C. I find I'm getting things done faster and faster in C++ as time goes on, especially compared with doing them in C. Constructors and destructors, for one, provide so much more support for getting things done in one place vs exploding interfaces in C and having error-prone open/close start/end procedure calls floating all over. As for performance, as you learn what the language is doing I don't think there's any reason that C++ is inherently weaker/slower than C - tho you can naively code powerful and inefficient constructs that look simple and do too much work ... something you couldn't do in C. Anyway, by far the biggest criticism I would level at C++ is that it's a hard language to learn - much harder than C to become expert at. I've heard others on the net echo this "steep learning curve" experience. I won't go back to C, but I wouldn't underestimate this cost either. Also I find it's lack of support for type-tags awkward: esp. for persistent objects (encouraging an impedance-mismatch problem with objects in memory vs. on-disk); and the fact that all virtual functions must take the same base-class argument types is awkward too (instead of more specialized versions of the same arguments, for example). Lack of exceptions is a bitch - but that's going away, I hope... (If anyone has written some preprocessor tools to implement C++ exceptions and templates as in ARM for the short-term, till compiler support is available - please let me know!) -- Jim Black (black@blake.u.washington.edu)