[Qt-interest] The C++ language committee

Gregory Seidman gsslist+qt at anthropohedron.net
Fri Apr 16 14:36:28 CEST 2010


I missed the original post, so I'm responding to both the original and a
reply. For the TL-DR crowd, each inline response stands alone, so feel free
to skip around.

On Fri, Apr 16, 2010 at 01:46:59PM +0200, Eirik Ulvik wrote:
> Den 16.04.2010 12:59, skrev Mihail Naydenov:
[...]
> > We all the story - C++0x and its features.
> > 
> > Two things however draw my attention:
> > 
> > First he mentions Qt, but as a negative example, he even added (IIRC)
> > "at least they did not come up with a proprietary language like some
> > others" sighting Apple .
[...]

I call bullshit. Objective-C and C++ were developed concurrently and
independently. C++ was C with the Simula concept of OO added. ObjC was C
with the Smalltalk concept of OO added. While AT&T commercialized
Stroustrup's invention, Tom Love and Brad Cox formed their own company to
commercialize ObjC. C++ saw its first commercial release in 1985, and ObjC
saw it first publication in 1986. All of this is from the languages'
respective Wikipedia pages.

Apple didn't come up with ObjC (and neither did NeXT, which licensed it
from Cox & Love's company). Also, C++ was a proprietary commercial product
from AT&T at first. These days, C++ has an international standard and ObjC
has a free reference implementation (i.e. GCC). Stroustrup doesn't have a
leg to stand on either implying that ObjC was some latecomer reaction to
C++ or that it's Apple's proprietary language.

> > Now, considering Qt is the most widely used, and possibly the best C++
> > framework, in the heart of some of the most demanding real word apps,
> > its is quite unfortunate it has no representative there!

I'd agree that Qt should be represented. There's a lot of trickery in the
whole signals and slots mechanism that could be implemented better at the
language level, if only to get some static analysis at compile time.

> > The benefits for the C++ community and the language itself will be huge. 
> > People love Qt. They not use it not because "its a necessary evil"
> > (like c++ IMHO itself is, not to mention the academic Boost (which does
> > the job never the less)), they use it, because they love it.
> > *This* is the real world modern C++. 
> > This C++ *should* be represented to let the committee k
> [/snip]
> I agree with all you have to say. Qt represents C++ as it should be, and
> as such should be represented in the standards committee.

A lot of programming, regardless of language, falls under the "necessary
evil" category. Anything in COBOL got there some time ago, much of what's
been written in C++ is there, and an awful lot of Java development is
headed there. For pretty much any system that is entirely in maintenance
mode (i.e. not active development so much as keeping things running
smoothly and integrating with new systems), touching the code is "a
necessary evil" and there is nothing to be done about that.

That said, one should use a language because it is the right tool for the
job. I'll use C++ and Qt for desktop development every time because it's
the right tool for it (unless I'm trying to sell an app to MacOS X users).
I wouldn't use C++ for web development, though, and I probably wouldn't
involve C++ in low-level system programming (e.g. kernel, embedded, etc.),
much less Qt. I'd probably use C# or Java if I had to do a lot of XML
manipulation or deal with SOAP services, and I'll use Ruby or sh/sed/awk
for scripting. Increasingly, I'll do small interactive apps entirely in
HTML/CSS/JavaScript. It's all a matter of the right tool for the job, and
it's important to realize than even though C++ and Qt are great hammers,
not everything is a nail.

> IMO new developers will not want to use the likes of boost which is just
> such a long way from other languages (C#, Java etc.) that students are
> taught and use at first.
> For me at least, Qt enabled me to start using C++ and actually enjoy it.

To paraphrase, "I don't want to use an unfamiliar language unless its
constructs and concepts match what I already know." If you already have a
hammer, do you get more benefit from another hammer ("oh, look, this one has
a metal handle!") or a drill? It's worth knowing lots of languages because
each language gets you to stretch your thinking in an unfamiliar way. The
more different the languages, the better. And the more tools you know, the
better you can be at picking the right one for the job at hand.

C++'s OO features are mediocre. They're tolerable, but even Java has a
better object model. The power and value unique to C++ is in the templating
language, and boost does a great job of offering that power in digestible
chunks. It behooves developers new to C++ to actually learn the language,
not just grasp the bits and pieces they understand from other languages
they know and start spewing code. C++ is an immensely complicated language,
and if you aren't getting an advantage out of that complexity (e.g. using
boost/STL/etc. templates and even writing your own templates) then you are
using the wrong language. The less complex parts of C++ just aren't that
impressive, though Qt does a pretty good job of making up for that.

I program professionally, but I'm also a hobbyist. I've been paid to
program in at least 10 languages (C, C++, ObjC, Java, VB.NET, C#, PL/SQL,
Ruby, JavaScript, even some assembly), but I know perhaps 20 more. That
gives me an edge at my job, and proficiency in my hobby. Strive for more
than just comfort and familiarity.

> Regards
--Greg




More information about the Qt-interest-old mailing list