Aliasing problems and final member variables

I hit a really stupid problem today, and I’ve only got myself to blame (as usual).

The problem was really simple. I was making an object that needed to know when it was created. This creation date wasn’t necessarily “now”, so I was passing a Calendar object in to the constructor of the object to represent the creation date.

Continue reading “Aliasing problems and final member variables”