Tech Off Post

Single Post Permalink

View Thread: Templated STL container pretty printer
  • User profile image
    Sven Groot

    Yeah, it's more of a feeling. Determining the nature of a type just by what members it has doesn't feel right to me, somehow. It doesn't feel like "proper OO", if there is such a thing. Wink

    By the way, the modified code you posted on SO has a couple of identifier (the #ifndef guard for the header file and the __value member of the helper struct) that start with double underscores. Names that begin with a double underscore (or a single underscore and a capital) are reserved for compiler and library implementations by the standard, so you shouldn't be using them in your code.