C++ Template Metaprogramming: Concepts, Tools, and Techniques from Boost and Beyond

by David Abrahams

C++ In-Depth Series

On This Page

Description

Abrahams and Gurtovoy have written something close to a classic... marvelous fun to read... Read the complete book review by Jack J. Woehr, Dr. Dobbs Journal, June 03, 2005 "If you're like me, you're excited by what people do with template metaprogramming (TMP) but are frustrated at the lack of clear guidance and powerful tools. Well, this is the book we've been waiting for. With help from the excellent Boost Metaprogramming Library, David and Aleksey take TMP from the laboratory to the show more workplace with readable prose and practical examples, showing that "compile-time STL" is as able as its runtime counterpart. Serving as a tutorial as well as a handbook for experts, this is the book on C++ template metaprogramming." --Chuck Allison, Editor, The C++ Source C++ Template Metaprogramming sheds light on the most powerful idioms of today's C++, at long last delivering practical metaprogramming tools and techniques into the hands of the everyday programmer. A metaprogram is a program that generates or manipulates program code. Ever since generic programming was introduced to C++, programmers have discovered myriad "template tricks" for manipulating programs as they are compiled, effectively eliminating the barrier between program and metaprogram. While excitement among C++ experts about these capabilities has reached the community at large, their practical application remains out of reach for most programmers. This book explains what metaprogramming is and how it is best used. It provides the foundation you'll need to use the template metaprogramming effectively in your own work. This book is aimed at any programmer who is comfortable with idioms of the Standard Template Library (STL). C++ power-users will gain a new insight into their existing work and a new fluency in the domain of metaprogramming. Intermediate-level programmers who have learned a few advanced template techniques will see where these tricks fit in the big picture and will gain the conceptual foundation to use them with discipline. Programmers who have caught the scent of metaprogramming, but for whom it is still mysterious, will finally gain a clear understanding of how, when, and why it works. All readers will leave with a new tool of unprecedented power at their disposal--the Boost Metaprogramming Library. The companion CD-ROM contains all Boost C++ libraries, including the Boost Metaprogramming Library and its reference documentation, along with all of the book's sample code and extensive supplementary material. show less

Tags

Recommendations

Member Reviews

3 reviews
In contrast to the book by Alexandrescu, this book provides a more structured approach to template-metaprogramming. I mainly describes the boost::MPL. The exercises were interesting and also demanding. Also, part of the idioms described here became part of the standard which underscores the importance of the presented material.

Unfortunately, I found the chapters about DSL's not self-contained and thus barely understandable.
Type-based (template) metaprogramming is one of the most powerful programming technologies available. Its also highly mind-expanding. If you're a true geek and you have a strong background in C++ this is for you. Otherwise, forget it!
Well, it is very interesting, but I estimate I understood like one third of it.

Members

Recently Added By

Lists

Books Read in 2021
5,361 works; 114 members

Author Information

5+ Works 123 Members

Series

Common Knowledge

Canonical title
C++ Template Metaprogramming: Concepts, Tools, and Techniques from Boost and Beyond

Classifications

Genres
Technology, Nonfiction, General Nonfiction
DDC/MDS
005.133Computer science, information & general worksComputer science, knowledge & systemsArtificial Intelligence/Virtual RealitySoftware developmentComputer programmingSpecific programming languages
LCC
QA76.73 .C153 .A325ScienceMathematicsMathematicsInstruments and machinesCalculating machinesElectronic computers. Computer science
BISAC

Statistics

Members
118
Popularity
275,343
Reviews
3
Rating
(3.96)
Languages
English, Korean
Media
Paper, Ebook
ISBNs
4
UPCs
1