Effective C++
Okay, so I've only been working with C++ for slightly more than a year and a half, but still... I should have known what Ruurd, Michael and Christian have been explaining. It's all in Effective C++, item 11, no less.
But in the heat of coding one tends to think one doesn't have to open a book, after all, let's just try one more little thing, and then it'll surely work. Not that I wouldn't have had time time to open the book; the KisColor class is so fundamental that any change in the header means recompiling all of Krita, which takes a lot of time, even on a 3Gh computer with 1 Gb of memory and a fast hard disk...
Well, I'm back to Java for the day's work now, which does have the advantage of being able to compile a few hundred classes in less than a minute. On the other hand, Tim Bray shows that Java is growing up: it's starting to be as confusing as C++
But I still should take the time to memorize the table of contents of Effective C++.