Vocabulary Types

It has been increasingly recognized over the past decade that one of the important roles of a standard language or standard library is to provide vocabulary types. A "vocabulary" type is a type that purports to provide a single lingua franca, a common language, for dealing with its domain.

Notice that even before C++ existed, the C programming language had already made a decent shot at the vocabulary of some areas, providing standard types or type aliases for integer math (int), floating-point math (double), timepoints expressed in the Unix epoch (time_t), and byte counts (size_t).

In this chapter we'll learn:

  • The history of vocabulary types in C++, from std::string to std::any
  • The definitions of algebraic data type, product ...

Get Mastering the C++17 STL now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.