C++17 In Detail

Hi there!

My name is Bartek, I'm a programmer from Cracow/Poland. This is my blog about C++ and native coding.

Quick jump links:

13 July 2020

5 Curious C++ Lambda Examples: Recursion, constexpr, Containers and More

Please have a look at my quick blog post where I’ll show you a few interesting lambda examples. Do you know how to write a recursive lambda? Store them in a container? Or invoke at compile time?

See in the article

29 June 2020

Polymorphic Allocators, std::vector Growth and Hacking

The concept of a polymorphic allocator from C++17 is an enhancement to standard allocators from the Standard Library.

It’s much easier to use than a regular allocator and allows containers to have the same type while having a different allocator, or even a possibility to change allocators at runtime.

Let’s see how we can use it and hack to see the growth of std::vector containers.

22 June 2020

The C++ Lambda Story Book

Lambda Expressions appeared in C++11, and since then they become one of the most distinguishing features of Modern C++. What’s more, with each revision of the Standard the ISO Committee improved the syntax and capabilities of lambdas, so they are even more comfortable to use.

Read on to see how you can learn all the details of this powerful modern C++ feature.

01 June 2020

C++ Lambdas, Threads, std::async and Parallel Algorithms

C++ Lambdas and multithreading, async

In articles about lambda expression (like this one from last week on my page), it’s easy to show examples where the lambda runs on the same thread as the caller. But how about asynchronous cases? What if your lambda is called on a separate thread? What problems you might encounter there.

Read on and let’s explore this topic.

25 May 2020

5 Advantages of C++ Lambda Expressions and How They Make Your Code Better

Lambda Expressions, C++, Advantages


The mixture of brackets in the preceding line become one of the most noticeable indications of Modern C++.
Lambda Expressions!
It might sound like I’m trying to create a new blog post about something that everyone knows. Is that true? Do you know all the details of this modern C++ technique?

In this article, you’ll learn five advantages of Lambdas. Let’s start.

18 May 2020

Spaceship Generator for May the 4th in C++ - Results!

Spaceship Random Generator, C++

Two weeks ago, I announced a little game on my blog! Today I’d like to present some of the solutions you sent me and discuss a few things from various aspects of Modern C++.

04 May 2020

Spaceship Generator for May the 4th in C++ - Enter The Game!

Spaceship Random Generator, C++

4th May is the Star Wars Day so why not join the celebration and build some space ships? Of course in C++ :)

Read on and see how to join the game and get a chance to win some extras!

27 April 2020

How to Use C++ for Azure Storage

How to Use C++ for Azure Storage

Blob storage is an object storage service you use in Azure. It is designed for storing large volumes of unstructured data, including text, binary data, images, and text. In this service, your data is stored in containerized blobs with a directory-like structure. You can use blob storage to ensure flexible access to storage, high availability, and data consistency. Read on to learn how you can use C++ with Azure storage.

20 April 2020

Notes on C++ SFINAE, Modern C++ and C++20 Concepts

Starting with C++ SFINAE

What is SFINAE? Where can you use this metaprogramming technique? Are there any better alternatives in Modern C++? And how about Concepts from C++20?

Read on to find out!

14 April 2020

How to Add Notes and Navigation Metadata Directly in Source Code in Visual Studio

Visual Assist HashTabs

Comments in code might not only be some text floating around the functions, variables and classes, but they might contain some extra semantic information. With this improvement, you can navigate through projects much faster or even organize your knowledge. In this blog post, I’ll show you two ways on how to add extra metadata to comments in Visual Studio.

06 April 2020

Runtime Polymorphism with std::variant and std::visit

std::variant and std::visit polymorphism

Runtime polymorphism usually connects with v-tables and virtual functions. However, in this blog post, I’ll show you a modern C++ technique that leverages std::variant and std::visit. This C++17 technique might not only offer better performance and value semantics, but also interesting design patterns.

23 March 2020

Vector of Objects vs Vector of Pointers And Memory Access Patterns

Memory access patterns are one of the key factors for writing efficient code that runs over large data sets. In this blog post, you’ll see why there might be a perf difference of almost 2.5x (in both directions!) when working with a vector of pointers versus a vector of value types.

Let’s jump in.

09 March 2020

Const collection of unique_ptr, options and design choices

Today I have one use case for you: how to declare a const collection of unique pointers of polymorphic types? Can we use std::vector? or maybe std::array? What are the options here? What if we’d like to have such collection as a class member? Have a look in the article.

02 March 2020

In-class Member Initialisation: From C++11 to C++20

With modern C++ and with each revision of the standard we get more comfortable way to initialise fields of a class: both static and non-static: there’s non-static data member initialisation (from C++11) and also inline variables (for static members since C++17).

In this blog post, you’ll learn how to use the syntax and how it changed over the years from C++11, through C++14, C++17 until C++20.

© 2017, Bartlomiej Filipek, Blogger platform
Disclaimer: Any opinions expressed herein are in no way representative of those of my employers. All data and information provided on this site is for informational purposes only. I try to write complete and accurate articles, but the web-site will not be liable for any errors, omissions, or delays in this information or any losses, injuries, or damages arising from its display or use.
This site contains ads or referral links, which provide me with a commission. Thank you for your understanding.