1493545295 Modern C++ Design: Generic Programming and Design Patterns Applied - General Programming - Books - Books - GameDev.net

Jump to content

Game Development Books

  • You cannot edit this book

Modern C++ Design: Generic Programming and Design Patterns Applied ****-

Modern C++ Design: Generic Programming and Design Patterns Applied By Andrei Alexandrescu
Published February 2001
List Price: $64.99, Your Amazon.com Price: $50.41

Amazon.com Sales Rank: 306,786
Availability: Usually ships in 24 hours

Generic Programming and Design Patterns Applied

Similar Books:

Buy it now:

  • You cannot edit this book


Dec 31 1979 06:00 PM
'State-of-the-art' generic programming in C++ (2000-2002).
The work-horse of the book is the TypeList construct with enables one to maintain and manipulate list of type-information at compile time.

With TypeList in hand, it is possible to automate the implementation of design patterns. Several GoF design patterns are implemented in template code are explained in the book.

The (template) policy based smart-pointer implementation may become part of the C++0x standard.

The SmallObjectAllocator mitigates object construction and destruction (takes about 400 CPU ticks to do both) for small objects, making typically high-overhead designs practical for performance sensitive code.

Generalized Functors make functions & methods (and other functors) first class citizens in C++, with full value semantics. An obvious application is implementing Undo/Redo, and an example is provided in the book.

At the time of publishing, very few compilers supported enough C++ to compile Loki (the name of the Modern C++ library). This has recently changed (Aug-2002), as Loki has been ported to gcc 2.95, Microsoft Visual C++ 7, Borland C++ Builder 6, & CodeWarrior 6.
Jul 16 2005 04:04 PM
This book is an excellent demonstration of how to apply advanced template metaprogramming to simple problems to arrive at a much more elegant solution.
I was surprised to see that the book solved quite a few problems I've thought about extensively in the past. Even for those problems of mine it didn't solve directly, it still shed quite a light on them and helped me discover elegant solutions that don't look like they've been hacked together by accident.