Peterhal – Last day at Microsoft

I’ve been promising myself an extended vacation for a long time now, but working at Microsoft has been so much fun I’ve kept postponing it. Well, this is it – my last day at Microsoft.   Feel free to email me at ‘hotweird’ at hotmail.

What Makes a Good Programmer?

I just read two salon articles about Scott Rosenberg’s new book Dreaming in Code. His thesis is that “programing is hard” and uses the experiences of the development of the Chandler project to frame the discussion. Scott identifies a common problem in large software development – inconsistent terminology use across the software development team. At the…


Code Review: Double Checked Locking Code

A friend of mine recently sent me some code to review:   Hi Peter, Do you have any suggestions on how to clean up this code? In particular the creation of a particular singleton type doesn’t look very pretty in this model:   private DoubleCheckedLock<SingletonClass> myInstance = new DoubleCheckedLock<SingletonClass>(); public SingletonClass Current {     get…


New F# Release.

Don Syme and the F# team have just released a new version of F#. Check it out here:   Peter

What Do Programmers Really Do Anyway? The data is in!

The smart folks over in the MSR-Human Interactions in Programming team have done some interesting research into the question of “What Do Programmers Really Do Anyway?”. I’m more than a little pleased to see that the data is consistent with the assertions I made in my previous blog posts. Some of their results are here:…


C# Automatically Implemented Properties – My Video Debut

Hey Folks, Charlie Calvert video taped our discussion on some of the new C# 3.0 features. Find it here: Cheers, Peter


What Do Programmers Really Do Anyway? (aka Part 2 of the Yardstick saga)

Way back in 2002 when we started working on Whidbey, I captured my thoughts on the direction we should take for C# and Visual Studio in two large emails. In the first email The Yardstick I spent a lot of time saying that you must evaluate features against the amount of time they save versus the…


C# Stumper: Why does this code not compile?

Hey folks, First off, I want to appologize for not having any activity on my blog for a while. I just got back from a wonderful 3 week vacation in Spain. Now that I’m back, rested and limber, here’s a twisted peice of C# code which is gauranteed to turn your brain inside out. Why does…


Many C# Questions: Switching on non-constant values.

I finally decided to play with the style settings on my blog. As you may have guessed, I’m a bit of a newbie when it comes to websites and blogging. Let me know what you think of the new look. Last weeks posting generated some great comments. Tzagotta asks:   Why are constant expressions required in…


Many Questions: Switch On Enum

Just a quick one this week:    Why is it that you cannot use enum constants in a switch statement’s cases without first casting them to type int?   Often you will want to use Enum constants as case labels in switch statements. Sometimes, the compiler will complain and require a cast to int on…