Articles & Books

Demystifying C++ lambdas -- Feabhas

In case you missed it:

Demystifying C++ lambdas

by Feabhas

From the article:

Lambdas are one of the new features added to C++ and seem to cause considerable consternation amongst many programmers. In this article we’ll have a look at the syntax and underlying implementation of lambdas to try and put them into some sort of context.

C++14 Is Out! -- Jose Daniel García

A view from our primary ISO representative from Spain, commenting on C++14's approval one week ago and providing a nice set of highlights showing what's new.

C++14 Is Out!

Jose Daniel García 

From the article:

After the long process that took a decade to produce C++11, the standards committee tried to define a more streamlined process to deliver updates and new versions of the C++ language and its standard library more frequently. The first target was to produce a new version for 2014. Now we can say that we have achieved the milestone.

... So, what’s new in C++14? In the language itself you will find a bunch of new/improved features. If you ask which is the most relevant new feature, the most common answer you may get is “generic lambdas”...

Near-final version of Effective Modern C++ available -- Scott Meyers

Scott's long-awaited book on using C++11 and C++14 is nearing completion:

Near-Final Draft of Effective Modern C++ Now Available (plus TOC and sample Item)

by Scott Meyers

From the announcement:

Effective Modern C++ is moving closer and closer to reality. This post contains:

  •     Information about availability of an almost-final draft of the book.
  •     The current (and probably final) table of contents.
  •     A link to the I-hope-I-got-it-right-this-time version of my Item on noexcept.

Note: Scott's session at CppCon ("Type Deduction and Why You Care") is based on the first chapter of Effective Modern C++.

Slashdot AMA responses from Bjarne Stroustrup

Hot off the presses, Stroustrup's answers to the most-upvoted questions (and a few more) from last week's AMA question thread.

Interviews: Bjarne Stroustrup Answers Your Questions 

Last week you had a chance to ask Bjarne Stroustrup about programming and C++. Below you'll find his answers to those questions. If you didn't get a chance to ask him a question, or want to clarify something he said, don't forget he's doing a live Google + Q & A today at 12:30pm Eastern. 

And don't forget that said live Q&A session starts in 20 minutes...

auto considered awesome -- Jarryd Beck

Today's op-ed from our Australian correspondent:

auto considered awesome

by Jarryd Beck

From the article:

 

My last post about why you might not want to use auto may have left some people thinking that I think you shouldn’t use it. In fact I think you should almost always use it...

 

A visitor’s guide to C++ allocators -- Thomas Köppe

The standard library allocators are one of the more mysterious parts of namespace std, as well as one of the more flexible parts. In this "under construction" article and GitHub repo, Thomas Köppe undertakes to demystify the feature.

A visitor’s guide to C++ allocators (repo)

by Thomas Köppe

From the README:

This repository contains a collection of documents that describe the allocator concept in the standard library of C++11 and beyond. The main guide covers the following topics.

  • Allocator traits
  • Statefulness
  • Fancy pointers
  • Allocator propagation in breadth (container copy, POC{CA,MA,S}) and depth (scoped_allocator_adaptor)

Start reading with the main guide.

Furthermore, there are several worked-out end-to-end examples:

The code for the end-to-end examples is available separately in the example_code directory.
 

Thoughts on C++14 -- Jens Weller

Jens Weller gives a nice perspective on the C++ landscape in 2014.

Thoughts on C++14

by Jens Weller

From the article:

Yesterday we could read on isocpp.org that C++14 has been approved and will now become a valid ISO Standard. Great news for everyone in the C++ land! ...

But there is something else that makes C++14 for me special...

Using Varadic Templates for a Signals and Slots Implementation in C++ -- Paul Cook

Fresh on GameDev.net:

Using Varadic Templates for a Signals and Slots Implementation in C++

By Paul Cook

From the article:

Abstract

Connecting object instances to each other in a type-safe manner is a well-solved problem in C++ and many good implementations of signals and slots systems exist. However, prior to the new varadic templates introduced in C++0x, accomplishing this has traditionally been complex and required some awkward repetition of code and limitations.

Varadic templates allow for this system to be implemented in a far more elegant and concise manner and a signals/slots system is a good example of how the power of varadic templates can be used to simplify generic systems that were previously difficult to express. ...