05979nam 22006375 450 991030065650332120200703093109.01-4842-1010-710.1007/978-1-4842-1010-9(CKB)3710000000412039(EBL)2094471(SSID)ssj0001501310(PQKBManifestationID)11840152(PQKBTitleCode)TC0001501310(PQKBWorkID)11523232(PQKB)11311583(DE-He213)978-1-4842-1010-9(MiAaPQ)EBC2094471(CaSebORM)9781484210109(PPN)186025998(EXLCZ)99371000000041203920150508d2015 u| 0engur|n|---|||||txtccrAdvanced Metaprogramming in Classic C++[electronic resource] /by Davide Di Gennaro1st ed. 2015.Berkeley, CA :Apress :Imprint: Apress,2015.1 online resource (554 p.)Expert's Voice in C++Description based upon print version of record.1-4842-1011-5 Includes bibliographical references and index.Contents at a Glance; PART 1: #include ; Chapter 1: Templates; 1.1. C++ Templates; 1.1.1. Typename; 1.1.2. Angle Brackets; 1.1.3. Universal Constructors; 1.1.4. Function Types and Function Pointers; 1.1.5. Non-Template Base Classes; 1.1.6. Template Position; 1.2. Specialization and Argument Deduction; 1.2.1. Deduction; 1.2.2. Specializations; 1.2.3. Inner Class Templates; 1.3. Style Conventions; 1.3.1. Comments; 1.3.2. Macros; 1.3.3. Symbols; 1.3.4. Generality; 1.3.5. Template Parameters; 1.3.6. Metafunctions; 1.3.7. Namespaces and Using Declarations; 1.4. Classic Patterns1.4.1. size_t and ptrdiff_t1.4.2. void T::swap(T&); 1.4.3. bool T::empty() const ; void T::clear(); 1.4.4. X T::get() const ; X T::base() const; 1.4.5. X T::property() const ; void T::property(X); 1.4.6. Action(Value) ; Action(Range); 1.4.7. Manipulators; 1.4.8. Position of Operators; 1.4.9. Secret Inheritance; 1.4.10. Literal Zero; 1.4.11. Boolean Type; 1.4.12. Default and Value Initialization; 1.5. Code Safety; 1.6. Compiler Assumptions; 1.6.1. Inline; 1.6.2. Error Messages; Long Template Stack; Implementation Details; Expanded Typedefs; Incomplete Types; 1.6.3. Miscellaneous TipsDon't Blame the CompilerKeep Warnings at the Default Level; Do Not Silence Warnings with "Dirty" Code Modifications; Maintain a Catalog of Compiler Bugs; Avoid Non-Standard Behavior; Don't Be Afraid of Language Features; Think About What Users of Your Code Would Do; 1.7. Preprocessor; 1.7.1. Include Guards; 1.7.2. Macro Expansion Rules; Chapter 2: Small Object Toolkit; 2.1. Hollow Types; 2 .1.1. instance_of; 2.1.2. Selector; 2.1.3. Static Value; 2.1.4. Size of Constraints; 2.2. Static Assertions; 2.2.1. Boolean Assertions; 2.2.2. Assert Legal; 2.2.3. Assertions with Overloaded Operators2.2.4. Modeling Concepts with Function Pointers2.2.5. Not Implemented; 2.3. Tagging Techniques; 2.3.1. Type Tags; 2.3.2. Tagging with Functions; 2 .3.3. Tag Iteration; 2 .3.4. Tags and Inheritance; PART 2: #include ; Chapter 3: Static Programming; 3.1. Static Programming with the Preprocessor; 3.2. Compilation Complexity; 3.3. Classic Metaprogramming Idioms; 3.3.1. Static Short Circuit; 3.4. Hidden Template Parameters; 3 .4.1. Static Recursion on Hidden Parameters; 3.4.2. Accessing the Primary Template; 3.4.3. Disambiguation; 3.5. Traits; 3.5.1. Type Traits3.5.2. Type Dismantling3.6. Type Containers; 3.6.1. typeat; 3.6.2. Returning an Error; 3.6.3. Depth; 3.6.4. Front and Back; 3.6.5. Find; 3.6.6. Push and Pop; 3.6.7 . More on Template Rotation; 3.6.8. Agglomerates; 3.6.9 . Conversions; 3.6.10. Metafunctors; 3.7. A Summary of Styles; Chapter 4: Overload Resolution; 4.1. Groups; 4.1.1. From Overload to Groups; 4.1.2. Runtime Decay; 4.2. More Traits; 4.2.1. A Function Set for Strings; 4.2.2. Concept Traits; 4.2.3. Platform-Specific Traits; 4.2.4. Merging Traits; 4.3. SFINAE; 4.3. 1. SFINAE Metafunctions; 4.3.2. Multiple Decisions; 4.3.3. Only_If4.3.4. SFINAE and Returned FunctorsAdvanced Metaprogramming in Classic C++ aims to be both an introduction and a reference to C++ template metaprogramming (TMP); TMP is presented in the book as a set of techniques that will bring a new style in C++ and make code exceptionally clear and efficient. The book deals with language aspects, design patterns, examples and applications (seen as case studies). Special emphasis is put on small reusable techniques that will improve the quality of daily work. What makes the book exceptional is the level of understanding of the concepts involved imparted by the author. This is not just a rote overview of metaprogramming. You will truly understand difficult topics like static assertions, how to write metafunctions, overload resolution, lambda expressions, and many others. More than that, you will work through them with practical examples guided by the author's frank explanations. This book requires you to think and to learn and to understand the language so that you can program at a higher level.Expert's voice in C++.Programming languages (Electronic computers)Programming Languages, Compilers, Interpretershttps://scigraph.springernature.com/ontologies/product-market-codes/I14037Programming languages (Electronic computers).Programming Languages, Compilers, Interpreters.004005.13Di Gennaro Davideauthttp://id.loc.gov/vocabulary/relators/aut892455UMIUMIBOOK9910300656503321Advanced Metaprogramming in Classic C++1993216UNINA