January 2004
-
:
New Year
A combination of events in the run up to my Christmas break meant that I have ended up spending almost 2 weeks without feeling the urge to write any code. I’ve just chilled out and relaxed, watched some DVDs, saw LOTR ROTK, played … -
:
2003, The year of the test
Looking back on my blog entries for 2003 it’s reasonably obvious that the big thing for me in 2003 was testing. TDD seems to work well for me and my clients. It’s not a silver bullet but it is a useful tool and I find that when … -
:
Use and misuse of C++ nested classes
I like nested classes in C++. They allow a nicely fine grained approach to naming. Where a class may need to be called CRegistryKeyIterator if declared at namespace level it can be called Iterator if nested inside the CRegistryKey class. … -
:
.Net 1.1 TcpClient strangeness
There seems to be a wierd bug with .Net 1.1 and sockets… In essence, this code: using System; using System.Net.Sockets; namespace ConsoleClient; { class Class1 { [STAThread] static void Main(string[] args) { TcpClient _socket = new … -
:
Template shims
I needed to implement the same interface twice in one object today. It took me a while to remember how I do this kind of thing so I thought it was worth a blog posting so that a) I can find it at a later date, b) other people can tell me of … -
:
In C++ why isn't this a reference?
In C++ every object has a “this” pointer. You could think of it as being passed as an implicit argument to every non static member function that the object has. It can never be null so why isn’t it a reference? The reason … -
:
Bitten by the one definition rule
I’ve just wasted 20 minutes or so on a nasty bug. I’d added a bit of test code and suddenly some other tests were failing but the reason for the failure seemed to be that a class’s vtable was getting screwed up and a … -
:
Back from Meribel
Just got back from a week’s skiing in and around Meribel. Great snow, great company, a good time was had by all. Just holiday snaps…. We stayed in the Indiana Lodge and travelled with VIP. Thanks to Eli and Al, our chalet … -
:
Oh good, comment spam
Just removed my first spam comments… It’s almost nice that the spammers think I’m worth spamming, but only almost… If this is anything like my email spam then I expect that this is just the start of a flood… … -
:
HeadCam2
My new head cam arrangement worked well in Meribel. As you can see from the picture below, the new camera is much smaller than my previous rig. The camcorder lives in my rucksack, the cables for video and remote control come out over my … -
:
Admitting that your baby's ugly
I have a couple of days to myself. We’ve just shipped some code to a client a couple of days ahead of schedule and we’re waiting to recieve a purchase order from another client so I find myself without any client work to do. … -
:
Hacking our way to the first test
So I have some time on my hands and I’ve decided that The Server Framework code could do with some tests but before I can do that I need to refactor because the code was written before I became test infected and, well, it’s not … -
:
How useful it could have been if...
I’m writing tests for some code. I have a function that I’m testing that looks something like this: bool CAsyncSocket::Read(bool throwOnFailure = false); If C++ allowed us to overload a function call based on return type then we … -
:
So, what do these tests look like then?
After breaking the socket server into more manageable chunks I started writing the tests. CAsyncSocketConnectionManager is pretty easy to test, it only has one public function; Connect(). So, what exactly do these tests look like? I … -
:
Ok, I'm curious
I get quite a bit of feedback about the socket server code but I don’t really know what people are using it for. So, if you can, leave a comment or drop me a mail and tell me. -
:
Knocked a few things off the list...
The refactoring and testing of The Server Framework code has gone pretty well. It’s not complete but at least we have some tests now and the code is broken down into slightly more cohesive lumps… Once the tests were in place …