February 2021

2021-02 Mailing Available

The 2021-02 mailing of new standards papers is now available.

 

WG21 Number Title Author Document Date Mailing Date Previous Version Subgroup
N4880 PL22.16/WG21 agenda: 22 February 2021, Virtual Meeting John Spicer 2021-01-23 2021-02   All of WG21
N4881 WG21 virtual meetings: 2021-02, -06, and -10 Herb Sutter 2021-02-08 2021-02   All of WG21
N4882 WG21 admin telecon meetings: 2021-02, -05, and -09 Herb Sutter 2021-02-08 2021-02   All of WG21
N4883 WG21 February 2021 admin telecon minutes Nina Ranns 2021-02-16 2021-02   All of WG21
P0401R6 Providing size feedback in the Allocator interface Chris Kennelly 2021-02-15 2021-02 P0401R5 LWG Library
P0448R3 A strstream replacement using span as buffer Peter Sommerlad 2021-02-17 2021-02 P0448R2 LWG Library
P0849R7 auto(x): decay-copy in the language Zhihao Yuan 2021-02-15 2021-02 P0849R6 EWG Evolution,LWG Library
P1018R8 C++ Language Evolution status pandemic edition 2020/11–2021/01 JF Bastien 2021-01-27 2021-02 P1018R7 EWG Evolution,All of WG21
P1072R7 basic_string::resize_and_overwrite Chris Kennelly 2021-02-15 2021-02 P1072R6 LWG Library
P1322R3 Networking TS enhancement to enable custom I/O executors Christopher Kohlhoff 2021-02-14 2021-02 P1322R2 SG4 Networking,LEWG Library Evolution
P1425R3 Iterators pair constructors for stack and queue Corentin Jabot 2021-02-18 2021-02 P1425R2 LEWG Library Evolution,LWG Library
P1659R2 starts_with and ends_with Christopher Di Bella 2021-02-10 2021-02 P1659R1 LWG Library
P1659R3 starts_with and ends_with Christopher Di Bella 2021-02-19 2021-02 P1659R2 LWG Library
P1682R3 std::to_underlying JeanHeyd Meneide 2021-01-22 2021-02 P1682R2 LWG Library
P1885R5 Naming Text Encodings to Demystify Them Corentin Jabot 2021-02-15 2021-02 P1885R4 SG16 Unicode,LEWG Library Evolution
P1951R1 Default Arguments for pair's Forwarding Constructor Logan R. Smith 2021-02-21 2021-02 P1951R0 LWG Library
P2047R1 An allocator-aware optional type Nina Ranns 2021-02-19 2021-02 P2047R0 LEWGI SG18: LEWG Incubator,LEWG Library Evolution
P2066R5 Suggested draft TS for C++ Extensions for Minimal Transactional Memory Jens Maurer 2021-02-14 2021-02 P2066R4 SG1 Concurrency and Parallelism,SG5 Transactional Memory,EWG Evolution,LEWG Library Evolution
P2093R4 Formatted output Victor Zverovich 2021-02-15 2021-02 P2093R3 LEWG Library Evolution
P2128R3 Multidimensional subscript operator Corentin Jabot 2021-02-15 2021-02 P2128R2 EWG Evolution
P2162R2 Inheriting from std::variant (resolving LWG3052) Barry Revzin 2021-02-17 2021-02 P2162R1 LEWG Library Evolution
P2164R4 views::enumerate Corentin Jabot 2021-02-18 2021-02 P2164R3 LEWG Library Evolution
P2195R2 Electronic Straw Polls Bryce Adelstein Lelbach 2021-01-27 2021-02 P2195R1 All of WG21
P2216R3 std::format improvements Victor Zverovich 2021-02-15 2021-02 P2216R2 LWG Library
P2231R1 Add further constexpr support for optional/variant Barry Revzin 2021-02-11 2021-02 P2231R0 LEWG Library Evolution
P2234R1 Consider a UB and IF-NDR Audit Scott Schurr 2021-02-13 2021-02 P2234R0 SG12 Undefined and Unspecified Behavior,EWGI SG17: EWG Incubator
P2242R1 Non-literal variables (and labels and gotos) in constexpr functions Ville Voutilainen 2021-02-14 2021-02 P2242R0 EWG Evolution,CWG Core
P2249R0 Mixed comparisons for smart pointers Giuseppe D'Angelo 2021-01-30 2021-02   LEWGI SG18: LEWG Incubator,LEWG Library Evolution
P2280R1 Using unknown references in constant expressions Barry Revzin 2021-02-15 2021-02 P2280R0 EWG Evolution
P2281R1 Clarifying range adaptor objects Tim Song 2021-02-19 2021-02 P2281R0 LWG Library
P2286R1 Formatting Ranges Barry Revzin 2021-02-19 2021-02 P2286R0 LEWG Library Evolution
P2287R1 Designated-initializers for base classes Barry Revzin 2021-02-15 2021-02 P2287R0 EWG Evolution
P2289R0 2021 Winter Library Evolution Polls Bryce Adelstein Lelbach 2021-01-31 2021-02   LEWG Library Evolution
P2290R0 Delimited escape sequences Corentin Jabot 2021-02-18 2021-02   SG22 Compatability,EWG Evolution
P2291R0 Add Constexpr Modifiers to Functions to_chars and from_chars for Integral Types in Header Daniil Goncharov 2021-01-28 2021-02   LEWGI SG18: LEWG Incubator,LEWG Library Evolution,LWG Library
P2295R0 Correct UTF-8 handling during phase 1 of translation Corentin Jabot 2021-02-15 2021-02   SG16 Unicode,SG22 Compatability,EWG Evolution
P2297R0 Wording improvements for encodings and character sets Corentin Jabot 2021-02-19 2021-02   SG16 Unicode
P2301R0 Add a pmr alias for std::stacktrace Steve Downey 2021-02-15 2021-02   LEWG Library Evolution,LWG Library
P2302R0 Prefer std::ranges::contains over std::basic_string_view::contains Christopher Di Bella 2021-02-10 2021-02   LEWG Library Evolution
P2303R0 Function literals and value closures Jens Gustedt 2021-02-10 2021-02   SG22 Compatability
P2304R0 Improve type generic programming Jens Gustedt 2021-02-10 2021-02   SG22 Compatability
P2305R0 Type inference for variable definitions and function returns Jens Gustedt 2021-02-10 2021-02   SG22 Compatability
P2306R0 Type-generic lambdas Jens Gustedt 2021-02-10 2021-02   SG22 Compatability
P2307R0 Lvalue closures Jens Gustedt 2021-02-10 2021-02   SG22 Compatability
P2309R0 A common C/C++ core specification Jens Gustedt 2021-02-11 2021-02   SG22 Compatability
P2310R0 Revise spelling of keywords Jens Gustedt 2021-02-11 2021-02   SG22 Compatability
P2311R0 Make false and true first-class language features Jens Gustedt 2021-02-11 2021-02   SG22 Compatability
P2312R0 Introduce the nullptr constant Jens Gustedt 2021-02-15 2021-02   SG22 Compatability
P2314R0 Character sets and encodings Jens Maurer 2021-02-12 2021-02   SG16 Unicode,EWG Evolution
P2315R0 C++ Standard Library Issues to be moved in Virtual Plenary, Feb. 2021 Jonathan Wakely 2021-02-12 2021-02   All of WG21
P2316R0 Consistent character literal encoding Corentin Jabot 2021-02-18 2021-02   SG22 Compatability,EWG Evolution
P2317R0 C++ - An Invisible foundation of everything Bjarne Stroustrup 2021-02-14 2021-02   All of WG21
P2320R0 The Syntax of Static Reflection Andrew Sutton 2021-02-15 2021-02   SG7 Reflection
P2321R0 zip Tim Song 2021-02-20 2021-02   LEWG Library Evolution
P2322R0 ranges::fold Barry Revzin 2021-02-18 2021-02   LEWG Library Evolution
P2323R0 maybe_unused attribute for labels Martin Uecker 2021-02-16 2021-02   SG22 Compatability
P2324R0 Labels at the end of compound statements (C compatibility) Martin Uecker 2021-02-16 2021-02   SG22 Compatability
P2325R0 Views should not be required to be default constructible Barry Revzin 2021-02-17 2021-02   LEWG Library Evolution

GotW #100 Solution: Preconditions, part 1 -- Herb Sutter

Solution just posted:

GotW #100 Solution: Preconditions, Part 1

by Herb Sutter

From the article:

We've seen how postconditions are directly related to assertions (see GotWs #97 and #99). So are preconditions, but that in one important way makes them fundamentally different. What is that? And why would having language support benefit us even more for writing preconditions more than for the other two?

Contribute your insights about C++ community – Developer Ecosystem 2021 survey

Every year we run an extensive survey on the IT communities all over the world. And we do share then results and the raw data with the community for free.

Contribute your insights about C++ to the coding community! Take the Developer Ecosystem 2021 survey. You can receive personalized survey results and you’ll have the chance to win an incredible prize.

Help us to gather insights about trends in the C++ community. Participate in the survey run by JetBrains and you’ll have the chance to win a prize! In addition, you can receive personalized survey results to compare yourself with other developers.

Fill it the survey!

A Recap on string_view--Jonathan Boccara

Back to the basics.

A Recap on string_view

by Jonathan Boccara

From the article:

The string capabilities of C++ have little evolved since C++98, until C++17 brought a major evolution: std::string_view.

Let’s look at what string_view is about and what it can bring to your code, by making it more expressive and making it run faster...

Complete C++20 Modules Support with GCC--Boris Kolpackov

More of c++20 ready to be used.

Complete C++20 Modules Support with GCC

by Boris Kolpackov

From the article:

build2 now provides conforming and scalable support for all the major C++20 Modules features when used with GCC. This includes named modules, module partitions (both interface and implementation), header unit importation, and include translation. All of these features are also supported in libraries, including consumption of installed libraries with information about modules and importable headers conveyed in pkg-config files. As part of this effort we have also created a collection of examples that demonstrate C++20 Modules features that impact the build process...

Take control of your vcpkg dependencies with versioning support--Victor Romero

A new feature.

Take control of your vcpkg dependencies with versioning support

by Victor Romero

From the article:

We have an exciting new feature to announce in vcpkg: the long-awaited and highly requested package versioning! This feature makes it possible to install specific versions of dependencies and control installed versions over time. In order to use this feature, a vcpkg.json manifest file must be present in your repo to declare dependencies. Versioning is not currently available for libraries installed via the command line (i.e. vcpkg install library_name commands). The versioning feature is completely optional – you can choose not to specify library versions, and vcpkg will pick the most appropriate set of compatible versions for your dependencies from its baseline catalog. For now, we are considering this feature experimental. Please give us your feedback and let us know how we can improve...

Introduction to GPU Programming with CUDA and Thrust -- Richard Thomson

Utah C++ Programmers has released a new video from their February meeting.

Introduction to GPU Programming with CUDA and Thrust

by Richard Thomson

From the video description:

High-performance computing is now dominated by general-purpose graphics processing unit (GPGPU) oriented computations. How can we leverage our knowledge of C++ to program the GPU?

NVIDIA's answer to general-purpose computing on the GPU is CUDA. CUDA programs are essentially C++ programs, but have some differences. CUDA comes as a Toolkit SDK containing a number of libraries that exploit the resources of the GPU: fast Fourier transforms, machine learning training and inference, etc. Thrust is a C++ template library for CUDA.

In this month's meeting, Richard Thomson will present a brief introduction to CUDA with the Thrust library to program the GPU.

Programming the GPU with CUDA is a huge topic covered by lots of libraries, tutorials, videos, and so-on, so we will only be able to present an introduction to the topic. You are encouraged to explore more on your own!

YouTube: https://www.youtube.com/watch?v=tbb835UFRQ4

Preconditions, Postconditions, Invariants - How They Help Write Robust Programs

An introduction to preconditions, postconditions and invariants.

Preconditions, Postconditions, Invariants –- How They Help Write Robust Programs

by Andrzej Krzemieński

From the video description:

Preconditions, postconditions, and invariants are part of what is often called Design by Contract, or Contract Programming. Even if you haven't heard of them, you are probably using them already. In this talk, we are going to see what they are, and how people and tools can make use of them.

unique_ptr, shared_ptr, weak_ptr, or reference_wrapper for class relationships -- Hitesh Kumar

Expressing class relationships with unique_ptr, shared_ptr, weak_ptr, and reference_wrapper.

unique_ptr, shared_ptr, weak_ptr, or reference_wrapper for class relationships

by Hitesh Kumar

From the article:

Classes communicate with each other by having handles as members that refer to other classes. The choice of those referring-handles (e.g., pointers or references) is mostly driven by ownership or control-over-lifetime semantics.