Revision History for:
Thinking in C++ 2nd edition
Volume 1: Introduction to Standard C++
See the end of this file for how to download the fonts used.
______________________________________________
Full text of Volume 1 & Volume 2, updates, source code and additional information available at www.BruceEckel.com.
______________________________________________
To be informed of future releases of this document and other information about object-oriented books, documents, seminars and CDs, subscribe to my free newsletter. Just send any email to: join-eckel-oo-programming@earth.lyris.net
______________________________________________
Revision history:
Sept 27, 2001: Small code corrections, in particular to allow compilation under G++ 3.0.1.
January 31, 2000: Added various corrections. Corrected some exercises. Changed from static const to the "enum hack" after conversations with Stroustrup and Koenig. This means that more of the examples will compile using VC++.
January 18, 2000: Added syntax highlighting in HTML version, courtesy of Zafir Anjum. Minor corrections. Added CD ROM license agreement and instructions at end of book.
TIC2VoneR13: January 13, 2000. Completed the index. Incorporated final copy edits. Barring corrections that pop up, this is the final version of the book.
TIC2VoneR12: January 1, 2000. With the help of James H Jarrett, reworked some of the use case material in Chapter 1. Various small corrections and mods.
TIC2VoneR11: December 27, 1999. Rewrote/finished Chapter 1. This completes the book; it is ready for final technical corrections; submit to Bruce@EckelObjects.com with the subject line [cpp2e-final-correction]. If you submitted a correction before, please check to see if I have accurately integrated your correction. Thank you for all your help.
Note the HTML version of the book has been greatly improved (thanks to Python) in anticipation of its distribution; please inform me if you find a flaw in the formatting.
TIC2VoneR10: December 23, 1999. Rewrote/finished Appendix A, B, & C. Rewrote the preface.
TIC2VoneR9: December 20, 1999. Corrected/Re-created all diagrams. Chapter 16 has been copy-edited.
TIC2VoneR8: December 15, 1999. Rewrote Chapter 16 & added exercises. All chapters except chapter 1 should be in their final form, from a technical standpoint. Chapters 12, 13, 14 & 15 have been copy-edited.
TIC2VoneR7: December 2, 1999. Rewrote Chapter 15 & added exercises. Chapter 11 has been copy-edited.
TIC2VoneR6: November 29, 1999. Rewrote Chapter 12 & added exercises. Rewrote Chapter 13 & added exercises. Rewrote Chapter 14 & added exercises. Chapter 4, 5, 6, 7, 8, 9 & 10 have been copy-edited. Fixed a bug in all the "stash" examples. Made the constructor calls more consistent throughout. Corrected files so that "make test" generally works (although VC++ doesn't handle the int main( ) return type as per the Standard, so it doesn't work for that). Changed all the examples from the const chapter on so that they have const member functions and take const& arguments where possible (that is, implemented const correctness).
TIC2VoneR5: November 1, 1999. Applied new formatting and fonts, corrected footers, fixed 'XX' chapter references. Added new chapter title-page graphics. Chapters 2 & 3 have been copy-edited.
TIC2VoneR4: September 30, 1999. Did a spell check. Changed most char* examples to strings. Changed most examples using class names "Base" and "Derived" to more easily-visualizable examples ("Pet" is used a lot) Changed require.h so that it uses string& arguments instead of char* (thus it works with both char* and string arguments). Began rewriting Chapter 12.
TIC2VoneR3: September 26, 1999. Added section on "Function addresses" and deciphering complex declarations to the end of Chapter 3, also added appropriate exercises. Rewrote Chapter 11 and added exercises.
TIC2VoneR2: September 24, 1999. Rewrote Chapter 10 and added exercises.
TIC2VoneR1: September 20, 1999. Broke the book into two volumes; this is volume one, which will be published approximately March 1, 2000 to meet the academic adoption date. Changed to revision numbering, reset to rev 1. Finished rewriting Chapter 9 and added exercises. Rewrote the preface to reflect the two volumes and the new chapter arrangement. Fixed the namespace examples in Chapter 10 so they actually generate compilable files. Integrated explicit cast syntax and modified examples into Chapter 3. Added section on downcasting to the end of Chapter 15.
TICA19: September 9, 1999. Started rewriting chapter 9. Then a reader comment about an error in a Stash or Stack example caused me to re-architect all those examples and their prose throughout the book, through Chapter 16 (Introduction to Templates). A lot of changes/new examples/re-architecting happened in Chapter 16. (The examples compile, but please test the execution of the examples and send error corrections.) Although I haven't made the final passes it is in pretty good shape. In addition, I added a new Stack example in Chapter 15 (Polymorphism), which shows the use of a container class in conjunction with a singly-rooted hierarchy (and a little multiple inheritance to boot). Rewrote some virtual destructor examples and prose in Chapter 15. Began making reference to Volume 2 of the book, as the book is going to be split into Volume 1 and Volume 2, the split occurring after chapter 16. The goal is to have Volume 1 in print by March 1 for academic adoption and Volume 2 a year after that. (Volume 2 will, of course, be available on the Internet in the meantime.)
TICA18: July 29, 1999. Rewrote Chapter 8 and added exercises. Replaced all later instances of the "enum hack" with static const (which breaks VC++ a lot, since they still haven't implemented this relatively ancient and simple feature). Added compiler support for Visual C++ 6.0 (+Service Pack 3) (although this hasn't been tested with Microsoft's nmake; you may need to edit the makefiles, copy nmake.exe to make.exe, or locate a gnu make in order to get it to work). You can see the results in CompileDB.txt in Appendix D. Re-tested all code with Borland C++ Builder 4 plus the downloadable update, and with egcs from July 18, 1999. Cleaned up some code files that were not being automatically compiled because they didn't have main( )s.
TICA17: June 27, 1999. Rewrote Chapter 6 and added exercises. Rewrote Chapter 7 and added exercises.
TICA16: June 1, 1999. Rewrote Chapter 5 and added exercises. Modifications to Chapter 19 before and after presentations at the SD conference. Added "Factories" section to design patterns chapter. Rechecked book code under May 24 build of egcs compiler.
TICA15: April 22, 1999. Rewrote Chapter 4 and added exercises.
TICA14, March 28, 1999. Rewrote Chapters 2 and 3. I think they're both finished. Chapter 3 is rather big since it covers C syntax fundamentals along with some C++ basics. Added many exercises to Chapters 2 and 3 to complete them both. Chapter 3 was a "hump" chapter; I think the others in section one shouldn't be as hard. Tried to conform all code in the book to the convention of "type names start with uppercase letters, functions and variables start with lowercase letters."
TICA13, March 9, 1999. Thorough rewrite of Chapter 1, including the addition of UML diagrams. I think Chapter 1is finished now. Reorganized material elsewhere in the book, but that is still in transit. My goal right now is to move through all the chapters in section one in order.
TICA12, January 15, 1999. Lots of work done on the Design Patterns chapter. All the existing programs are now modified and redesigned (significantly!) to compile under C++. Added several new examples. Much of the prose in this chapter still needs work, and more patterns and examples are forthcoming. Changed ExtractCode.cpp so that it generates "bugs" targets for each makefile, containing all the files that won't compile with
Thinking in C++, 2nd edition, Volume 1
需积分: 0 6 浏览量
更新于2008-08-26
收藏 871KB RAR 举报
《Thinking in C++, 2nd edition, Volume 1》是一本C++编程领域的经典著作,由Bruce Eckel撰写。这本书的第二版第一卷主要聚焦于C++的基础概念和语法,旨在帮助初学者深入理解C++编程的核心思想。通过阅读本书,读者可以掌握面向对象编程的基本原理,以及如何有效地使用C++语言进行程序设计。
1. **C++语言基础**:C++是C语言的扩展,增加了类、模板、异常处理等面向对象特性。书中的章节将详细讲解C++的变量、数据类型、运算符、流程控制语句(如if、for、while)以及函数的使用。
2. **面向对象编程**:C++的核心在于其面向对象编程(OOP)的概念,包括类、对象、封装、继承和多态。书中会深入探讨这些概念,帮助读者理解如何通过类来设计数据结构和操作,并通过对象实例化来实现代码复用。
3. **构造与析构函数**:C++中的构造函数用于初始化对象,而析构函数则在对象生命周期结束时执行清理工作。这两者在管理对象生命周期时至关重要。
4. **操作符重载**:C++允许用户为已有的操作符定义新的行为,这一特性在自定义数据类型中非常有用,如自定义加法或比较操作。
5. **动态内存管理**:C++提供了动态内存分配和释放的机制,如new和delete操作符,理解这些概念对于避免内存泄漏和提高程序效率至关重要。
6. **指针和引用**:C++的指针和引用是其强大功能的一部分,它们提供了对内存的直接访问。指针可以指向对象的地址,而引用是对象的别名,两者都是在编写高效代码时经常使用的工具。
7. **模板**:C++的模板是一种泛型编程工具,可以创建函数和类的通用版本,从而实现代码复用。模板分为函数模板和类模板,它们在实现泛型算法和容器(如STL)时起着关键作用。
8. **异常处理**:异常处理是C++中处理程序运行时错误的一种方式,通过try、catch和throw关键字,可以在出现问题时优雅地恢复程序的正常运行。
9. **标准模板库(STL)**:STL是C++的标准库,包含了容器(如vector、list、set)、迭代器、算法和函数对象,是C++编程中不可或缺的一部分。
10. **实践与案例分析**:书中不仅讲解理论知识,还提供丰富的编程实例,让读者通过实践加深理解。此外,提供的教程源码可供读者实际操作,以加深对所学知识的应用。
《Thinking in C++, 2nd edition, Volume 1》是学习C++编程的宝贵资源,无论你是初学者还是有一定经验的开发者,都能从中受益匪浅。通过系统学习,你可以掌握C++的基础,为进一步探索C++的高级特性及应用打下坚实基础。
好吧好吧1234567
- 粉丝: 27
- 资源: 6
最新资源
- 02-【管理流程】-30-薪酬发放流程图.docx
- 行为驱动开发 (BDD) 和 Tes 质量指标的比较数据集-最新出炉.zip
- IMF分量显著性检验:EEMD分解中的真实信号判别与能量谱属性分析,imf的显著性检验 对输入信号进行eemd分解,然后对imf分量进行显著性检验 文中的蓝线是0.05置信区间,红线是0.01置信
- 基于MPC与ADRC的车速控制算法研究:实现期望加速度与节气门制动控制,适用于燃油汽车,可用于实车试验与车速需求控制,附带复现资料 ,基于模型预测MPC和自抗扰adrc实现的车速控制,控制目标为燃油汽
- 各种企业与员工解除和终止劳动合同通知书.docx
- 《解除劳动合同协议书》两范本及说明.doc
- 解除劳动合同的情形及程序.xlsx
- 解除或终止劳动合同通知书.doc
- 解除劳动合同通知工会函.doc
- 解除劳动合同通知书(单方解除).docx
- 解除劳动合同协议书.doc
- 解除劳动合同书(最新).doc
- 解除劳动合同协议书(正常离职版).doc
- 旷工解除劳动合同的模板-公告、通知书.docx
- 劳动合同解除协议(主动离职).doc
- 终止解除劳动合同通知书(全套).doc