Talk:C++ Standard Library
This is the talk page for discussing improvements to the C++ Standard Library article. This is not a forum for general discussion of the article's subject. |
Article policies
|
Find sources: Google (books · news · scholar · free images · WP refs) · FENS · JSTOR · TWL |
Archives: 1Auto-archiving period: 2 months ![]() |
![]() | This article has not yet been rated on Wikipedia's content assessment scale. It is of interest to the following WikiProjects: | |||||||||||||||||||||||||||||
Please add the quality rating to the {{WikiProject banner shell}} template instead of this project banner. See WP:PIQA for details.
Please add the quality rating to the {{WikiProject banner shell}} template instead of this project banner. See WP:PIQA for details.
|
This is the talk page for discussing improvements to the C++ Standard Library article. This is not a forum for general discussion of the article's subject. |
Article policies
|
Find sources: Google (books · news · scholar · free images · WP refs) · FENS · JSTOR · TWL |
Archives: 1Auto-archiving period: 2 months ![]() |
GNU C++ Library
Why it is not mentioned in the text? Is there a reason for that? What about LLVM's implementation? — Preceding unsigned comment added by 2804:431:CFFB:BFC5:528C:3C3C:A5AF:E8CE (talk) 21:48, 5 July 2020 (UTC)
C++ Standard Library vs STL
The article: "Although the C++ Standard Library and the STL share many features, neither is a strict superset of the other" makes it sound that they are two similar but not exactly the same. The side bar gives the impression they are not the same at all:
The "C++ Standard Library" constains all streams, the C Standard Library, and then also contains the STL, which contains all the rest.
Also, most of the information in the body of the article is redundant with the info from Standard Template Library. I think it should be made clearer who is a part of what. And if the STL is a part of the C++ Standard Library, then some merging needs to be done. 82.150.248.28 (talk) 14:07, 16 June 2010 (UTC)
- It's *not* "a part of the C++ Standard Library". The term "STL" has fallen into the vernacular to refer to those parts of the C++ Standard Library that were based on the STL, but to begin merging the two articles would be a backwards step. Tomalak Geret'kal (talk) 22:33, 4 July 2011 (UTC)
Reorganization of the articles about C++ containers
Currently there's quite a lot of mess in the articles about C++ containers. A lot of content is duplicated across articles about similar containers. Also, we have quite much material that is reference manual-like or too detailed. I think the situation could be improved by reorganization. My suggestion is that we implement the same structure as in the C++ standard:
- Sequence containers (C++) -
array
,vector
,list
,forward_list
,deque
, - Associative containers (C++) -
map
,set
,multimap
,multiset
- Unordered associative containers (C++) -
unordered_map
,unordered_set
,unordered_multimap
,unordered_multiset
- Container adaptors (C++) -
queue
,stack
,priority_queue
Since each article would cover similar containers, there would be quite less content duplication. The quality of the articles would increase, since the material such as differences among containers could be covered in one place. Lastly, the WP:NOTMANUAL issue would be reduced: the function listings could be merged (I think we could have tables similar to [1], just not for all containers at once and maybe using different style), the functionality itself could be compared, and examples merged. Any thoughts? 1exec1 (talk) 20:01, 2 December 2011 (UTC)
- I agree for merging all these articles as User:1exec1 proposes. Recently I had a kind of dispute concerning WP:NOTMANUAL about code in the article Queue (abstract data type), where all the code examples of queue has been removed: [2]. Adding code - examples demonstrating a container is valuable. Having a workable example a reader can evaluate what has been reading in the article and the article is not becoming a manual. Ggia (talk) 14:03, 3 December 2011 (UTC)
- I've merged the first batch of articles. Please see how it looks. The target page needs quite a lot of copy-editing and cleanup now, though the main ideas have been implemented. 1exec1 (talk) 00:08, 6 December 2011 (UTC)
C++ Standard Library: proper noun or not?
There's an ongoing discussion about whether C++ Standard Library is a proper noun or not. Please express your opinion. 1exec1 (talk) 17:43, 3 December 2011 (UTC)
History and versions
In this article I am missing information about the history: When was it proposed? What was the first implementations? Different years/dates for various versions? Dependency on versions of C++?
--Mortense (talk) 13:48, 12 April 2020 (UTC)
- The history of the C++ Standard Library is, by definition, tied to the history of the C++ standard itself, and every new version of the C++ standard defines a corresponding version of the C++ Standard Library. (See C++98, C++03, C++11, C++14, C++17, and C++20 for that.)
- The first version of the C++ standard (i.e. C++98) already contained much of Stepanov's Standard Template Library, and Jerry Schwarz's iostreams library. I seem to have mislaid my copy of Stroustrup's book "The Design and Evolution of C++", and I can't say what it has to say about the history of the "pre-standard C++ standard library", so to say. There's however a "History" section in Stroustrup's The C++ Programming Language. Quoting from section 1.4.2.1 "Language Features and Library Facilities" (a subsection of 1.4.2 "The Early Years"):
Section 1.4.3 talks about the 1998 standard. Section 1.4.3.2, titled "The Standard Library" has this to say:The C++ language evolved hand in hand with some of the key library facilities presented in this book. For example, I designed the complex, vector, stack, and (I/O) stream classes together with the operator overloading mechanisms. The first string and list classes were developed by Jonathan Shopiro and me as part of the same effort. ... The development of the template facility was influenced by a variety of vector, map, list, and sort templates devised by Andrew Koenig, Alex Stepanov, me, and others.
The greatest and most important innovation in the 1998 standard was the inclusion of the STL, a framework of algorithms and containers, in the standard library. It was the work of Alex Stepanov (with Dave Musser, Meng Lee, and others) based on more than a decade's work on generic programming. Andrew Koenig, Beman Dawes, and I did much to help get the STL accepted. ... Except for the STL, the standard library was a bit of a hodgepodge of components, rather than a unified design. ... The standard-library string had its origins in early work by Jonathan Shopiro and me at Bell Labs but was revised and extended by several different individuals and groups during standardization. The valarray library for numerical computation is primarily the work of Kent Budge. Jerry Schwarz transformed my streams library into the iostreams library using Andrew Koenig's manipulator technique and other ideas. The iostreams library was further refined during standardization, where the bulk of the work was done by Jerry Schwarz, Nathan Myers, and Norihiro Kumagai.
- (One note: A conforming implementation of standard C++ needs to provide the functionality of the C++ Standard Library. However, strictly speaking, the C++ standard library need not be implementable in standard C++.) – Tea2min (talk) 18:01, 12 April 2020 (UTC)
- There's two papers by Stroustrup that mention some of the history of the C++ Standard Library:
- A History of C++: 1979-1991. Proc ACM History of Programming Languages conference (HOPL-2). ACM Sigplan Notices. Vol 28 No 3, pp 271-298. March 1993.
- There's a section "5.3 Libraries" in that paper but not much of would become the C++ Standard Library.
- Evolving a language in and for the real world: C++ 1991-2006. ACM HOPL-III. June 2007.
- There's a section "4. The Standard Library: 1991-1998", with section 4.1 about the STL and section 4.2 "Other Parts of the Standard Library"
- Perhaps these papers can be condensed into a "History" section of C++ Standard Library. – Tea2min (talk) 20:39, 12 April 2020 (UTC)