On Friday 18th January I’ve pushed another update for the book. This time I rewrote the whole chapter about std::filesystem
. Please have a look at what changed and what are the plans.
The book got more than 25 new pages!
Read more...On Friday 18th January I’ve pushed another update for the book. This time I rewrote the whole chapter about std::filesystem
. Please have a look at what changed and what are the plans.
The book got more than 25 new pages!
Read more...Welcome to new C++ Links - most important and useful articles, podcasts and videos that happen between 26th of January and 1st of February 2019.
This week you will find a link to all 177 papers before next ISO C++ Meeting in Kona, link to an article that sums up the current state of C++ Modules and many more!
Read more...Welcome to new C++ Links - most important and useful articles, podcasts and videos that happen between 2nd and 8th of February 2019.
In this week you will find a link to interesting CMake features, a detailed description of the std::rotate
algorithm and many more!
While I was doing research for my book and blog posts about C++17 several times I stumbled upon this pattern for visitation of std::variant
:
template<class... Ts> struct overload : Ts... { using Ts::operator()...; };
template<class... Ts> overload(Ts...) -> overload<Ts...>;
std::variant<int, float> intFloat { 0.0f };
std::visit(overload(
[](constint& i) { ... },
[](constfloat& f) { ... },
),
intFloat;
);
With the above pattern, you can provide separate lambdas “in-place” for visitation.
It’s just two lines of compact C++ code, but it packs a few interesting concepts.
Let’s see how this thing works and go through the three new C++17 features that enable this one by one.
Read more...Welcome to new C++ Links - most important and useful articles, podcasts and videos that happen between 9th and 15th of February 2019.
In this week you will find a link to a great post about a technique that can help reduce compilation time, an article that explains how Smart Iterators are working and many more!
Read more...I’m just in time (I hope)! In a few hours, a new C++ISO meeting will start! This time the committee gathered in Kona, Hawaii for their first meeting in 2019.
Let’s see what’s already in C++20 and let’s have a look at some smaller, but very handy proposals that might get into the standard.
Read more...Welcome to new C++ Links - most important and useful articles, podcasts and videos that happen between 16th and 22nd of February 2019.
This week you will find a link to a few interesting papers from the Kona ISO C++ Meeting, how to set bitmask using Designated Initializers and many more!
Read more...Lambda expressions are one of the most powerful additions to C++11, and they continue to evolve with each new C++ language standard. In this article, we’ll go through history and see the evolution of this crucial part of modern C++.
Read more...Welcome to new C++ Links - most important and useful articles, podcasts and videos that happen between 23rd February and 1st of March 2019.
This week we have a massive update on the upcoming C++ Standard - Kona Meeting reports. Then you can also read about the history of lambdas, about smart iterators and more.
Read more...I released “C++17 In Detail” in August 2018, and I set the status to 90%. I didn’t expect that writing of that remaining 10% would take me so long :) Now it’s high time to set the counter to 100%.
That’s why I’m pleased to announce that my book “C++17 In Detail” is now done!
See the recent changes, a new code sample and check out the promo!
Welcome to new C++ Links - most important and useful articles, podcasts and videos that happen between 2nd and 8th of March 2019.
This week you will find links to articles about accepted Modules proposal, a great MSVC improvement that is reducing binaries with C++ exceptions by 20% and many more!
Read more...In the first part of the series we looked at lambdas from the perspective of C++03, C++11 and C++14. In that article, I described the motivation behind this powerful C++ feature, basic usage, syntax and improvements in each of the language standards. I also mentioned several corner cases.
Now it’s time to move into C++17 and look a bit into the future (very near future!): C++20.
Read more...The C ++ 17 standard consists of almost two thousands pages. Two thousand pages describing every single aspect of the language. Some pages relates to all kinds of details, exceptions, and things that you do not care about every day. We will try to look at a few such cases, which we hope never see in the production code.
Read more...Lambdas are one of the most prominent and useful elements of modern C++. They can significantly reduce the code and make it more expressive. The feature might look easy, but there are a lot of details that you need to know to master it. This free ebook will help you with that!
Read more...Welcome to new C++ Links - most important and useful articles, podcasts and videos that happen between 23th and 29th of March 2019.
This week you will find links to a detailed comparison of using static vs dynamic libraries, how we can discover code smell using static analyser and many more!
Read more...It’s April Fool’s Day, so let’s have some fun :) Last year I announced fake news about C++: deprecation of Raw Pointers and two years ago I wanted to have C++18. So what’s coming this time?
A quiz!
Answer the questions, and find two that makes no sense and don’t have any correct answer… can you solve such test?
Read more...Welcome to new C++ Links - most important and useful articles, podcasts and videos that happen between 30th of March and 5th of April 2019.
Read more...Welcome to new C++ Links - most important and useful articles, podcasts and videos that happen between 6th and 12th of April 2019.
In this week you will find the link to post about co_awaiting coroutines, link to an article how to write spaceship operator with std::tuple
& CRTP pattern and many more!
How would you implement a function that searches for files with a given extension? For example, finding all text files? or *.cpp files? To code that solution you need a way to iterate through directories. Is that possible in C++ out of the box using the standard library? Let’s see some techniques and new elements that C++17 added.
Read more...