Meeting 5 December 2019
How can you be so certain?
We are defining a language for decades of use. A bit of humility is necessary.
Bjarne Stroustrup on Lex Fridman’s AI Podcast
Belfast trip reports
CLion 2019.3
A Quality-Targeted Release Focused on Performance and Some Long-Awaited Enhancements
MinGW Distro 17.0: GCC 9.2.0 and Boost 1.71.0 for Windows
I’ve maintained this distro for over 14 years, and I still don’t serve ads, sell anything, or accept donations.
Sourcetrail is now free and open-source software
When is it justified to use C++ for a project?
Is it time for a rebased Boost2 that assumes C++20 as its starting point?
TL;DR: No.
Eliminating the Static Overhead of Ranges
Without ranges
1vector<string> child_names;
2for (auto& person : all_people) {
3 if (person.age < 14) {
4 child_names.push_back(person.name);
5 }
6}
With ranges
1auto children_names =
2 all_people
3 | filter([](const auto& person) { return person.age < 14; })
4 | transform([](const auto& person) { return person.name; })
5 | to_vector;
The arrow operator
The
operator->
has special semantics in the language in that, when overloaded, it reapplies itself to the result. While the rest of the operators are applied only once,operator->
will be applied by the compiler as many times as needed to get to a raw pointer and once more to access the memory referred by that pointer.
1struct A { void foo(); };
2struct B { A* operator->(); };
3struct C { B operator->(); };
4struct D { C operator->(); };
5int main() {
6 D d;
7 d->foo();
8}
Thanks to Martin Waplington for suggesting this.
Quote
Ellen Ullman:
We build our computer (systems) the way we build our cities: over time, without a plan, on top of ruins.