Chapter 13. Strings
This chapter presents the string types of the C++ standard library. It describes the basic class template basic_string<> and its standard specializations string, wstring, u16string, and u32string.
Strings can be a source of confusion because it is not clear what the term string means. Does it mean an ordinary character array of type char* (with or without the const qualifier)? Is it an instance of class string<>? Or is it a general name for objects that are kinds of strings? In this chapter, I use the term string for objects of one of the string types in the C++ standard library: string, wstring, u16string, or u32string. For “ordinary strings” of type char* or const char*, I use the term C-string.
Note that with C++98 the ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access