C++ Annotated: Apr – Aug 2017--Anastasia Kazakova
Did you miss something?
C++ Annotated: Apr – Aug 2017
by Anastasia Kazakova
From the article:
Today we are happy to share our next compilation of C++ news with you.
June 16-21, Sofia, Bulgaria
September 13-19, Aurora, CO, USA
October 25, Pavia, Italy
November 6-8, Berlin, Germany
November 16-21, Kona, HI, USA
By Adrien Hamelin | Aug 29, 2017 12:57 PM | Tags: experimental community
Did you miss something?
C++ Annotated: Apr – Aug 2017
by Anastasia Kazakova
From the article:
Today we are happy to share our next compilation of C++ news with you.
By Adrien Hamelin | Aug 29, 2017 12:43 PM | Tags: intermediate c++17
A handy new feature:
C++17: Inline Variables
by Marc Gregoire
From the article:
Before C++17, if your class had any non-const static data members, you had to allocate memory for them.
By Adrien Hamelin | Aug 28, 2017 01:09 PM | Tags: efficiency c++11
You use threads? You should know this.
Top 20 C++ multithreading mistakes and how to avoid them
by Deb Haldar
From the article:
Threading is one of the most complicated things to get right in programming, especially in C++. I've made a number of mistakes myself over the years. Most of these mistakes were luckily caught in code review and testing ; however, some arcane ones did slip through and make it into production code and we had to patch live systems, which is always expensive.
In this article, I've tried to catalog all the mistakes I know of, with potential solutions. If you know any more pitfalls, or have alternative suggestions for some of the mistakes – please leave a comment below and I'll factor them into the article.
By bfilipek | Aug 23, 2017 10:23 AM | Tags: performance c++17
Let’s see how C++17 can make writing parallel code a bit easier.
C++17 in details: Parallel Algorithms
by Bartlomiej Filipek
From the article:
With C++17 we get a lot of algorithms that can be executed in a parallel/vectorized way. That’s amazing, as it’s a solid abstraction layer. With this making, apps is much easier. A similar thing could be achieved possibly with C++11/14 or third-party APIs, but now it’s all in the standard.
By Adrien Hamelin | Aug 23, 2017 09:19 AM | Tags: intermediate c++17
THe series continue.
C++17 in details: Parallel Algorithms
by Bartlomiej Filipek
From the article:
Writing multithreaded code is hard. You’d like to utilize all of the machine’s processing power, keeping code simple and avoid data races at the same time.
Let’s see how C++17 can make writing parallel code a bit easier.
By Adrien Hamelin | Aug 21, 2017 12:10 PM | Tags: community
ACCU’s Overload journal of June 2017 is out. It contains the following C++ related articles.
From the journal:
Editorial: Gnomes and Misnomers.
What's in a name? Frances Buontempo decides some names are better than others.The Path of the Programmer.
Charles Tolman provides a framework for personal development.A Usable C++ Dialect that is Safe Against Memory Corruption.
Sergey Ignatchenko continues his investigation of allocators for (Re)Actors.Metaclasses: Thoughts on Generative C++.
Herb Sutter shows how metaclasses could simplify C++ with minimal library extension.A C++ Developer Sees Rustlang for the First Time.
Katarzyna Macias provides an introduction to Rust for a C++ developer.Portable Console I/O via iostreams.
Alf Steinbach describes how his library fixes problems streaming non-ASCII characters in Windows.A Functional Alternative to Dependency Injection in C++.
Satprem Pamudurthy showcases a functional alternative to dependency injection in C++.About the C++ Core Guidelines.
Andreas Fertig shows us the C++ core guidelines.Afterwood.
Chris Oldwood reminds us to fix the problem, not to blame.
By Adrien Hamelin | Aug 18, 2017 12:11 PM | Tags: intermediate c++11
Quick Q: Delete its constructor
Recently on SO:
Make C++ fail compilation on specific instantiation of template function
Since foo is a complete specialization, it will always get compiled, and the static assert will always get called.
However, there’s an easier way:
template <> Bar foo<Bar>(Bar val) = delete;This will say that this specific version is deleted, and cannot be called.
By Eric Niebler | Aug 17, 2017 03:56 PM | Tags: intermediate experimental c++20
Eric Niebler shares his thoughts about the interaction of ranges and co-routines in his recent blog post.
Ranges, Coroutines, and React: Early Musings on the Future of Async in C++
by Eric Niebler
From the article:
Another way to look at this is that synchronous ranges are an example of a pull-based interface: the user extracts elements from the range and processes them one at a time. Asynchronous ranges, on the other hand, represent more of a push-based model: things happen when data shows up, whenever that may be. This is akin to the reactive style of programming.
By using ranges and coroutines together, we unify push and pull based idioms into a consistent, functional style of programming. And that’s going to be important, I think.
By Adrien Hamelin | Aug 15, 2017 01:51 PM | Tags: intermediate c++11
The series continues.
Your own error condition
by Andrzej Krzemieński
From the article:
In the previous post we have seen how you can create your own error-code enumeration for representing different reasons for failure in your component, and how you can store them and convey them type erased via std::error_code. In this post we will see how you can inspect an error situation encoded in std::error_code, and how you can build useful queries about error conditions.
By Adrien Hamelin | Aug 14, 2017 02:48 PM | Tags: c++17 basics
C++17 is almost there.
7 Features of C++17 that will simplify your code
by fenbf
From the article:
With each C++ standard, we aim for simpler, cleaner and more expressive way to code. C++17 offers several "big" language features that should make our code nicer. Today, I tried to pick seven things that make your code more compact right off the bat.