More discussion on boost/format.hpp.
The history of template exports and why no compiler implents them.
Bjarne is giving a talk soon at BoostCon on a “wish list” for the C++ standard library. He would like suggestions emailed (bs at cs.tamu.edu or bs at research.att.com) to him on the community’s thoughts.
As it is now, ~10% of boost will be in the C++0x standard library.
Stroustrup’s new book: “Programming – Principles and Practice using C++” (due Aug 2008)
Sutter’s new book: “Effective Concurrency” (due Dec 2008)
Bjarne has respect for the Boost libraries. Boost has no special standing, but they try to have portable libraries that could be candidates for the standards. Not every boost library can, or should, be in the standard.
Tuesday, March 4, 2008
boost/format.hpp is cool
get the correctness of iostreams with the ease of printf
ex: cout << format(str) % “info”;
ex: cout << format(str) % “info”;
Concepts and Generic Programming in C++0x
Bjarne Stroustrup and Herb Sutter
Background
C++ Templates: high-level of abstraction and close to the hardware
Spectacularly bad error messages
Classic example: Primer number calculation during compilation
C++0x: Concepts
“A type system for C++ types”
Combinations of types
Aims and Ideals
Direct expression of intent
Separate checking of template definitions and template uses
No performance degradation
Current templates remain valid
Usable in current toolchain
Status
A design
Implementation of design: ConceptGCC (search ‘WG21’)
Lots of examples, papers, etc
Next: Correctness, Performance, Maintainability, Flexibility/Generality, Compensability
Language features are there to support ways of thinking; shouldn’t/can’t define a programming style simply as using a language feature.
Generic programming is sometimes referred to as “algorithm oriented” as opposed to “object oriented.”
An example, going from concrete to abstract, and how Concepts aim to helps.
Discussion on coding concepts. C++98 STL type traits (documented in the standard in English) are now codified using Concepts.
Background
C++ Templates: high-level of abstraction and close to the hardware
Spectacularly bad error messages
Classic example: Primer number calculation during compilation
C++0x: Concepts
“A type system for C++ types”
Combinations of types
Aims and Ideals
Direct expression of intent
Separate checking of template definitions and template uses
No performance degradation
Current templates remain valid
Usable in current toolchain
Status
A design
Implementation of design: ConceptGCC (search ‘WG21’)
Lots of examples, papers, etc
Next: Correctness, Performance, Maintainability, Flexibility/Generality, Compensability
Language features are there to support ways of thinking; shouldn’t/can’t define a programming style simply as using a language feature.
Generic programming is sometimes referred to as “algorithm oriented” as opposed to “object oriented.”
An example, going from concrete to abstract, and how Concepts aim to helps.
Discussion on coding concepts. C++98 STL type traits (documented in the standard in English) are now codified using Concepts.
Subscribe to:
Posts (Atom)