Many Questions: Generics Variance

One of the main benefits of the addition of generics to C# is the ability to easily create strongly typed collections using types in the System.Collections.Generics namespace. For example, you can create a variable of type List<int>, and the compiler will check all accesses to the variable – ensuring that only ints are added to…


Many Questions: general catch clause

I’m back from my course on Software Design. Now that we are starting to think about the version of C# after VS 2005 we are shining a bright light on all the ways the current compiler codebase could be better. This is the fun part of the product cycle where you get to really dig…


Out this week …

I’ve been out this week taking a great course on designand architecture. For those interesed in the evolution of C#, check this out 


Many Questions: switch on type

I hope everyone had a good fourth of July weekend. I certainly did. I spent the weekend hiking around the Olympic peninsula with my girlfriend and capped it off watching the fireworks here in Seattle. On to our question of the week: We get a lot of requests for addditions to the C# language and today…


Many Questions: Protected Constructors

Well here it is, one week into my many questions series and I’m already late for the second issue. I have a good reason though, as I took a long weekend to rock climb out at Stone Hill near Eureka Montana. If you are into climbing, I highly recommend it – Stone Hill has a…


Many Questions: User defined conversions and Interfaces

I get a lot of questions about the rationale behind the design of the C# language. Over the next few months I’m going to try and make a point of posting a C# language design question up here every Monday. This week’s question comes from Erik Meier. I was wondering what the reason is to…


A Quick note on using statements in C#

Nicholas Paldino( noticed a change in the C# using statement between Beta 1 and Beta 2 of VS 2005. Here’s the full story … In V1 and V1.1, the C# compiler accepted only types implementing IDisposable in using statements. In Beta1 of Whidbey we added support for the pattern based resource types, and in Beta2 we reverted…



Hey Folks, I just wanted to let you all know that I’m busy working on getting Whidbey out and into your hot little hands and I won’t have time to post here for a few weeks. Cheers, Peter


Mark the Date! April 21st- Chat with the C# Language Team

The C# team is hosting a chat about the C# language design on April 21st. This is a great opportunity to find out more abouthow and why the C# language works the way it does. Find more info here:


More Nullable Info …

Luca Bolognese, our intrepid C# compiler PM, posted some interesting Nullable info