Thomas Becker's Free Software Utilities

Supplements and Extensions to the STL under VC6 (obsolete, but historically interesting)

The C++ Standard Committee had the foresight to admit the STL into the Standard as early as the mid-1990's. At that time, and for years to come, scepticism against using the STL in serious software projects ran high, in academic circles as well as in commercial software engineering. This was of course because compiler support for the STL was rather sketchy at the time. In particular, Microsoft's VC6, the compiler of choice (or shall we say coercion?) for many commercial software projects, was lacking support for many features that are essential for generic programming, such as partial template specialization and template template parameters.

Around that time, I was hired as the second team member for a large software project whose technical lead had decided to make generic programming and the STL a cornerstone of the project's design and implementation. This decision, originally frowned upon by many, has since turned out to be an extremely fortuitous one. However, the first five years or so of trying to use the STL and the generic programming paradigm under VC6 were rather laborious. There was hardly a day where you did not run into some little thing or other; today, it was mem_fun not working for const member functions, tomorrow it was mem_fun not working for member functions returning void, and so on and so on.

I ended up building quite a collection of supplements and workarounds to overcome these shortcomings of VC6. Since most of that work was done on my own time, I made many of these utilities available in the public domain (see, e.g., my article in C/C++ Users Journal of June 2000).

Since we were using the STL and generic programming massively in a large and complex software project, we soon discovered the need for certain extensions to the STL such as iterator adaptors and composition of functors. This was at a time when not only these things were unavailable in Boost; in fact, there was no Boost at all back then. We ended up with VC6-specific, spit'n-duct-tape versions of many utilities that are now a staple in the Boost library. Primitive as they were, these utilities were much appreciated by the few people who were doing serious software development with the STL at the time. At the risk of sounding pompous, I must say that I am still proud of the fact that my friend and colleague Christopher Baus and I had production-quality versions of practically all the specialized iterator adaptors that are now in Boost, together with a CUJ article and a follow-up article that were the first to introduce the idea behind iterator adaptors.

But all of this is water under the bridge now. With today's STL implementations and all the amazing stuff that's available in Boost, we can finally experience the true joy of generic programming. But then again, the good old pioneer days will always be remembered...