Advanced C++ Programming
Training Targeted to Your Organization's Particular Needs
Description
There is no
standard curriculum for advanced C++, because C++ is a large language
with many associated patterns, idioms, and programming
techniques. Different parts of the language and different idioms
and techniques apply depending on the technical area of
development. Typically we'll cover an advanced core of "Common
Knowledge" with which all professional C++ programmers should be
familiar, and add additional modules suitable to your area of C++
application. Some of the available modules are
- Prelude: Knowledge Assessment "Quiz" and Review
- Recent Language and Library Additions
- Hierarchy Design Idioms
- Advanced Memory Management
- Template Mechanics
- Template Programming Techniques
- Copying, Conversions, and Temporaries
- Exceptions
- Pointers, References, and Smart Pointers
- Callable Entities
- Design Patterns in the C++ Context
- The Standard Template Library
- TR1 Library Extensions
Audience
This course is designed
to serve the needs of experienced software
engineers
with good, basic knowledge of C++, and may be
customized to the individual client's application
domain, project, staff experience level, and scheduling requirements.
Format
4-5 days,
lecture/lab
Texts
Copies of the course
materials, with extensive explanatory notes.
Sample Outline
Below is a possible outline for a five-day course. Other
orderings, lengths, and topics are available.
- Prelude: Knowledge Assessment "Quiz"
- Storage Classes
- Inheritance and Polymorphism
- Array/Pointer Duality
- Const Correctness
- Well-Defined, Platform-Dependent, and Undefined Behavior
- Recent Language and Library Additions
- New-Style Casts
- RTTI
- Namespaces
- Library Organization
- Coding for TR1 Compatibility Using Boost
- Template Mechanics
- Class Templates
- Function Templates
- Implicit Template Requirements and the Role of Convention
- Function Template Argument Deduction and Overloading
- Class Template Specialization
- Non-Type Template Parameters
- Template Template Parameters
- SFINAE and INCINI
- Explicit Instantiation
- Exception Handling
- The Purpose of Exception Handling
- Syntax and Mechanics of the Exception Handling Mechanism
- Throwing Exceptions
- Handling Exceptions
- Exception Specifications
- Designing Exception Types
- Designing for Exceptions
- More Exception Features
- Memory Management
- new and delete Operators
- New Handlers
- Exceptions and Memory Management
- Placement New and Explicit Destruction
- Member operator new and operator delete
- Array new and delete Operators
- Copying, Conversions, and Temporaries
- Assignment and Initialization
- Copy Operations and Class Mechanism
- Copying Problems
- Implementing Copy Operations
- User-Defined Conversions
- Unintended Conversions and explicit
- Conversions, Temporaries, and Efficiency
- Computational Constructors
- Temporaries and Copy Construction
- Direct vs. Copy Initialization
- Return Value Optimizations
- Conversions, Temporaries, and References
- Temporary Lifetime and Correctness
- C++ Pointers
- References
- const and Pointers
- const Member Functions
- const and References
- Multilevel Pointers and References to Pointers
- Arrays
- typedef and Type Sinks
- The Meaning of Pointer Comparison
- void * and Casting
- Smart Pointers
- Advanced Template Programming Techniques
- Template Member Functions
- Helping the Compiler to Parse Templates
- Templated Copy-Like Operation Idiom
- Making New Friends Idiom
- The Curiously-Recurring Template Pattern
- Generic Algorithms and Abstraction
- Parameterizing with C++-Callable Entities
- Helper Function Idiom
- Overloading and Specializing Function Templates
- Function Template Partial Specialization Idiom
- Nested Type Information and Traits
- Policy-Based Design
- Type Algebras and Compile Time Type Information
- Introduction to Type Lists
- Introduction to Expression Templates
- Hierarchy Design Idioms
- Data Abstraction
- The Template Method Pattern
- The Nonvirtual Interface Idiom
- Base Class Member Roles
- Overloading, Overriding, and Hiding
- Hierarchies and Polymorphism
- Type-Based Conditional Code
- Cosmic Hierarchies
- Hierarchies and Reuse
- Substitutability
- Totalitarianism, Tough Love, and Reuse
- Contracts and Leveraging Polymorphic Code
- Interfaces
- dynamic_cast
- Capability Queries
- Degenerate Hierarchies
- Design for Repair
- Composition of Simple Hierarchies
- Abstract Bases, Slicing, and Copying