1 Oct 2005 cdfrey   » (Journeyer)

Thanks to all the folks that bumped me up to Apprentice, which lets me comment on articles. Much appreciated.

ncm:

    Monotone

    What made you pick Monotone? I haven't yet made the time to evaluate all the distributed source control systems yet to find which one I like best, so I'm always eager to hear other people's reasons for their choices.

    The ever present C++ debate

    What worries me about the indulgence of template based generic programming over OO inheritance and virtual functions is that with templates, you are duplicating code for each type you wish to code for. This doesn't happen with OO, albeit with a slight performance hit of virtual functions.

    This code duplication caused by templates is fine for code that you'd normally write anyway. For example, for_each instead of for loops, or any similar small piece of code.

    But the larger your template functions become, the more each instance costs every time you use it.

    Take the mozilla string hierarchy currently in discussion. How would you use templates to provide the same string functionality without the code duplication of templates? Mozilla is plenty big enough as it is.

    Creating template versions of the mozilla string class, perhaps parameterized with the various functionality as template arguments, would cause each function that needed a general string argument to be a template as well, to accept whatever the user passed in. Am I missing something obvious here?

    I must be, because there are a lot of C++ gurus that keep saying inheritance is bad, but tend not to go into detail. :-)

Latest blog entries     Older blog entries

New Advogato Features

New HTML Parser: The long-awaited libxml2 based HTML parser code is live. It needs further work but already handles most markup better than the original parser.

Keep up with the latest Advogato features by reading the Advogato status blog.

If you're a C programmer with some spare time, take a look at the mod_virgule project page and help us with one of the tasks on the ToDo list!