-
Addison Wesley C++ Programming Language The 4th Edition 2013下载
资源介绍
The C++ programming language / Bjarne Stroustrup.—Fourth edition.
pages cm
Includes bibliographical references and index.
ISBN 978-0-321-56384-2 (pbk. : alk. paper)—ISBN 0-321-56384-0 (pbk. : alk. paper)
1. C++ (Computer programming language) I. Title.
QA76.73.C153 S77 2013
005.13’3—dc23 2013002159
Copyright © 2013 by Pearson Education, Inc.
C++ feels like a new language. That is, I can express my ideas more clearly, more simply, and
more directly in C++11 than I could in C++98. Furthermore, the resulting programs are better
checked by the compiler and run faster.
In this book, I aim for completeness. I describe every language feature and standard-library
component that a professional programmer is likely to need. For each, I provide:
• Rationale : What kinds of problems is it designed to help solve? What principles underlie
the design? What are the fundamental limitations?
• Specification: What is its definition? The level of detail is chosen for the expert program
mer; the aspiring language lawyer can follow the many references to the ISO standard.
• Examples : How can it be used well by itself and in combination with other features? What
are the key techniques and idioms? What are the implications for maintainability and per-
formance?
Part I: Introductory Material
1. Notes to the Reader ..............................................................3
2. A Tour of C++: The Basics ........................................................37
3. A Tour of C++: Abstraction Mechanisms ............................................59
4. A Tour of C++: Containers and Algorithms .........................................87
5. A Tour of C++: Concurrency and Utilities .........................................111
Part II: Basic Facilities 133
6. Types and Declarations ...........................................................135
7. Pointers, Arrays, and References .................................................171
8. Structures, Unions, and Enumerations .............................................201
9. Statements ........................................................................225
10. Expressions ......................................................................241
iv Contents
11. Select Operations ................................................................273
12. Functions ........................................................................305
13. Exception Handling ...............................................................343
14. Namespaces .......................................................................389
15. Source Files and Programs .......................................................419
Part III: Abstraction Mechanisms 447
16. Classes ..........................................................................449
17. Construction, Cleanup, Copy, and Move ...........................................481
18. Overloading ......................................................................527
19. Special Operators ................................................................549
20. Derived Classes ..................................................................577
21. Class Hierarchies ................................................................613
22. Run-Time Type Information .......................................................641
23. Templates ........................................................................665
24. Generic Programming ..............................................................699
25. Specialization ...................................................................721
26. Instantiation ....................................................................741
27. Templates and Hierarchies .......................................................759
28. Metaprogramming ..................................................................779
29. A Matrix Design .................................................................827
Part IV: The Standard Library 857
30. Standard Library Summary ........................................................859
31. STL Containers ...................................................................885
32. STL Algorithms ...................................................................927
33. STL Iterators ....................................................................953
34. Memory and Resources ............................................................973
35. Utilities ........................................................................1009
36. Strings ..........................................................................1033
37. Regular Expressions .............................................................1051
38. I/O Streams ......................................................................1073
39. Locales ..........................................................................1109
40. Numerics .........................................................................1159
41. Concurrency ......................................................................1191
42. Threads and Tasks ................................................................1209
43. The C Standard Library ..........................................................1253
44. Compatibility ....................................................................1267