Stroustrup: Why the 35-year-old C++ still dominates 'real' dev

C++ inventor details the language's latest changes and assesses the strengths and weaknesses of its competitors

Page 2 of 2

InfoWorld: I'm looking at the blurb about an upcoming keynote you're presenting. It says, "C++ faces two challenges: helping programmers address the most demanding tasks in terms of performance, scale, and dependability. It also must help programmers be productive writing ordinary maintainable code." What can be done about these issues?

Stroustrup: I'm trying to explain the two things. One is to delve into efficient abstraction, efficient use of hardware, and the other one was simplifying writing new code, and with C++ 11 and C++ 14, there are some new facilities for that.

There's a new minor edition of the standard coming out this year, which is what we refer to as C++ 14. It's already shipping from Clang and GCC. The way I describe it is that C++14 is completing the work we did for C++ 11. When you are shipping a big product, which C++ 11 was, there are some things don't make it in just because you have to ship. And there's a few things you can't get right until you have everything put together and try it. And C++ 14 is [offering] things like that that didn't make it into C++ 11.

Instead of just the lambdas we had in C++ 11, we now have generic lambdas, and the lambdas can capture using move semantics, things like that. These are fairly technical things -- function, return, type deduction goes on just like for lambdas. The "constexpr" functions functions -- functions that you can do at compile time -- can now contain simple For loops. We have variable templates, there's improvements in memory initialization. There's user-defined literals.

InfoWorld: What about the issue of security in programming? Is there anything that developers need to do as far as securing their programs? Is C++ a more secure language than others?

Stroustrup: I'm a great fan of hardware to aid security. In terms of programming languages, if you want to write good programs, write your code type-safe. You can do that in C++. Don't mess around with low-level features all the time. And don't go to fully general interpreters where you can't track what is going on. Basically, security is a systems issue.

InfoWorld: Is there anything else you want to say about C++ or anything else in software development these days?

Stroustrup: We should aim for a greater degree of professionalism in software development. There are things in our society that musn't break, and most of them depend on software. And we need to consider our systems as a whole. Languages and their tool chains are part of it. We need to look into how we educate our developers and how we put emphasis on reliability.

This story, "Stroustrup: Why the 35-year-old C++ still dominates 'real' dev," was originally published at Get the first word on what the important tech news really means with the InfoWorld Tech Watch blog. For the latest developments in business technology news, follow on Twitter.

| 1 2 Page 2
From CIO: 8 Free Online Courses to Grow Your Tech Skills
View Comments
Join the discussion
Be the first to comment on this article. Our Commenting Policies