作者:David Abrahams, Aleksey Gurtovoy
副书名:Concepts, Tools, and Techniques from Boost and Beyond
出版日期:December 10, 2004
出版社:Addison Wesley
页数:400
ISBN:0-321-22725-5
文件格式:CHM
“If you’re like me, you’re excited by what people dowith template metaprogramming (TMP) but are frustrated at the lack ofclear guidance and powerful tools. Well, this is the book we’ve beenwaiting for. With help from the excellent Boost MetaprogrammingLibrary, David and Aleksey take TMP from the laboratory to theworkplace with readable prose and practical examples, showing that“compile-time STL” is as able as its runtime counterpart. Serving as atutorial as well as a handbook for experts, this is the book on C++template metaprogramming.”Chuck Allison, Editor, The C++ Source
C++ Template Metaprogramming shedslight on the most powerful idioms of today’s C++, at long lastdelivering practical metaprogramming tools and techniques into thehands of the everyday programmer.
A metaprogram is a program that generates ormanipulates program code. Ever since generic programming was introducedto C++, programmers have discovered myriad “template tricks” formanipulating programs as they are compiled, effectively eliminating thebarrier 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. Itprovides the foundation you’ll need to use the template metaprogrammingeffectively in your own work.
This book is aimed at any programmer who iscomfortable with idioms of the Standard Template Library (STL). C++power-users will gain a new insight into their existing work and a newfluency in the domain of metaprogramming. Intermediate-levelprogrammers who have learned a few advanced template techniques willsee where these tricks fit in the big picture and will gain theconceptual foundation to use them with discipline. Programmers who havecaught the scent of metaprogramming, but for whom it is stillmysterious, will finally gain a clear understanding of how, when, andwhy it works. All readers will leave with a new tool of unprecedentedpower at their disposalthe Boost Metaprogramming Library.
The companion CD-ROM contains all Boost C++libraries, including the Boost Metaprogramming Library and itsreference documentation, along with all of the book’s sample code andextensive supplementary material.