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

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

作者: David Abrahams Aleksey Gurtovoy
出版社: Addison Wesley
出版在: 2004-12-10
ISBN-13: 9780321227256
ISBN-10: 0321227255
裝訂格式: Paperback
總頁數: 408 頁





內容描述


Table of Contents:

Preface.
Acknowledgments.
Making the Most of This Book.

  1. Introduction.
        Getting Started.
        So What's a Metaprogram?
        Metaprogramming in the Host Language.

    Metaprogramming in C++.
    Why Metaprogramming?
    When Metaprogramming?
    Why a Metaprogramming Library?

  1. Traits and Type Manipulation.
        Type Associations.
        Metafunctions.
        Numerical Metafunctions.
        Making Choices at Compile Time.

    A Brief Tour of the Boost Type Traits
Library.
    Nullary Metafunctions.
    Metafunction Definition.
    History.
    Details.
    Exercises.

  1. A Deeper Look at Metafunctions.
        Dimensional Analysis.
        Higher-Order Metafunctions.
        Handling Placeholders.
        More Lambda Capabilities.
        Lambda Details.
        Details.
        Exercises.
  2. Integral Type Wrappers and Operations.
        Boolean Wrappers and Operations.

    Integer Wrappers and Operations.

     Exercises.

  1. Sequences and Iterators.
        Concepts.
        Sequences and Algorithms.
        Iterators.
        Iterator Concepts.
        Sequence Concepts.
        Sequence Equality.
        Intrinsic Sequence Operations.

    Sequence Classes.
    Integral Sequence Wrappers.
    Sequence Derivation.
    Writing Your Own Sequence.
    Details.
    Exercises.

  1. Algorithms.
        Algorithms, Idioms, Reuse, and
    Abstraction.
        Algorithms in the MPL.
        Inserters.
        Fundamental Sequence Algorithms.

    Querying Algorithms.
    Sequence Building Algorithms.

    Writing Your Own Algorithms.

    Details.
    Exercises.

  1. Views and Iterator Adaptors.
        A Few Examples.
        View Concept.
        Iterator Adaptors.
        Writing Your Own View.
        History.
        Exercises.
  2. Diagnostics.
        Debugging the Error Novel.
        Using Tools for Diagnostic Analysis.

    Intentional Diagnostic Generation.

    History.
    Details.
    Exercises.

  1. Crossing the Compile-Time/Runtime Boundary.

    for each.
    Implementation Selection.
    Object Generators.
    Structure Selection.
    Class Composition.
    (Member) Function Pointers as Template
Arguments.
    Type Erasure.
    The Curiously Recurring Template
Pattern.
    Explicitly Managing the Overload Set.

    The "sizeof Trick".
    Summary.
    Exercises.

  1. Domain-Specific Embedded Languages.
        A Little Language.
        Goes a Long Way.
        DSLs, Inside Out.
        C++ as the Host Language.
        Blitz++ and Expression Templates.

    General-Purpose DSELs.
    The Boost Spirit Library.
    Summary.
    Exercises.

  1. A DSEL DesignWalkthrough.
        Finite State Machines.
        Framework Design Goals.
        Framework Interface Basics.
        Choosing a DSL.
        Implementation.
        Analysis.
        Language Directions.
        Exercises.
    Appendix A. An Introduction to Preprocessor
    Metaprogramming.
        Motivation.
        Fundamental Abstractions of the
    Preprocessor.
        Preprocessor Library Structure.

    Preprocessor Library Abstractions.

    Exercise.
Appendix B. The typename and template Keywords.

    The Issue.
    The Rules.
Appendix C. Compile-Time Performance.
    The Computational Model.
    Managing Compilation Time.
    The Tests.
Appendix D. MPL Portability Summary.
Bibliography.
Index.




相關書籍

電腦硬體裝修丙級檢定學術科解題教本|Windows 10 + Ubuntu 18 (第二版)

作者 胡秋明.林文恭研究室

2004-12-10

Unity 5實戰: 使用C#和Unity開發多平臺遊戲

作者 霍金 (Joseph Hocking)

2004-12-10

Towards 5G: Applications, Requirements and Candidate Technologies (Hardcover)

作者 Rath Vannithamby Shilpa Talwar

2004-12-10







2
2
2