|
|
Re: Bjarne Stroustrup on Concepts and the Future of C++
|
Posted: Aug 17, 2009 8:28 AM
|
|
> > Bottom line: There are a lot of people with strong > > opinions about what should be done, but rather scarce > > resources of people who are both able and willing to do > > the actual work, and you can't expect them to do your > > work. > > I don't understand how it's my work now. In this day and > age, people specialize in certain things. We ask > politicians to fix social problems, we ask the C++ > committee to fix the language's problems.
Right, and they put a lot of effort into improving the language, often with their own time and money.
Given that the committee is a volunteer effort, the members will work on what they think is important. This is why you can't tell them what to do, but you (anyone) _can_ contribute to the direction of the development of C++, by becoming involved in the committee work, yourself.
This is no different from any other language out there (except any language funded by taxpayer money, perhaps).
> > > What is needed by the majority of projects is: > > > > > > 1) a language that runs native code. > > > 2) a language that maximizes reuse of code. > > > 3) a language that is is safe, but it can become > unsafe > > if > > > required (for performance reasons). > > > > > > C++ succeeds in #1 (because it does not need a > virtual > > > machine - although it's irrelevant if a language runs > > on > > > an emulator or not in the end) and #2 (due to > > templates), > > > but it fails completely at #3. > > > > I disagree with the assessment of #3. A lot of work has > > gone into C++ to tighten up the type system, and other > > things, to make it a safer language to use. > > Still, C++ is a statically and weakly typed language.
I guess it depends on your perspective. As others have pointed out, much of the weaknesses of C++'s type system is inherited from C, and C compatility was (and is) a conscious decision, for better or worse.
A language making a clean break from C would had very slim chances of succeeding. Thus, it makes sense to build on a successful language (you advocate that a new language should be compatible with C++, yourself), and then tighten it up.
> > > Personally, I would use ADA, but the world is fixed > on > > > C/C++. > > > > In such a world it may make a lot of sense to > contribute > > to trying to make a mainstream language like C++ a > better, > > safer language, than inventing a new one, which has > little > > hope of succeeding (as the plethora of existing > languages > > attest to). > > No, if the new language is compatible with C in a > straightforward manner, and its simple enough, then it can > succeed. People will enjoy writing libraries for it (both > for psychological and economical reasons).
I think you've answered your own question: A new language wouldn't be accepted by your management. :) (and probably for good reason)
Myself, I don't even use C++ nowadays; I work with web application development, using PHP, which is more or less an untyped language, and have been doing so for several years. From this respective, C++ appears as a very strongly typed language. :)
Like you, I have bills to pay, and I can't dictate the language being used at work. We have lots of code written using PHP, so it's simply not practical (it won't make any economic sense) to rewrite it in another language.
Yet, I enjoy playing with other languages on my own free time, including - of all things - an ARM processor assembler, written in ARM assembly code (about 25,000 lines of code). which I made over a decade ago, and which I'm now updating to the lastest ARM versions.
Apart from this, I've looked at and played some with other high-level languages, like Smalltalk, Lisp, Scheme and Haskell.
There are ways of enjoying other languages, even if you may not be able to use them at work.
To put this discussion in perspective: You can at least use a statically typed language. I don't have even that. :) Yet, I'm not expecting the PHP community to toss out the language, and make one to my liking...
|
|