Code, rants and ramblings of a programmer.
Browse by Tags
Tagged Content List
Extension Methods and the Debugger
One source of confusion I find myself clearing up a lot is the use of evaluating extension methods in the debugger windows. Users report evaluation as working sometimes but not others for the exact same piece of code. Such flaky behavior can only be the result of a poorly implemented feature...
22 Jul 2010
Using F# Discriminated Unions in C# (Beta2)
While updating my VsVim editor extensions for Beta2  I got hit by a change in the way F# exposed discriminated unions in metadata. My extension consists of a core F# component with a corresponding set of unit tests written in C#. It’s mostly API level testing and as such I use a lot of...
27 Oct 2009
Extension Methods and ByRef targets
One of the seldom used, and often unknown, features of VB extension methods is that the argument of the extension method (the first parameter) can be passed by reference. This gives extension methods the power to change the reference that was used to invoke the value! Obviously this can produce...
11 Dec 2008
Calling Extension Methods on Null Objects
One of the gotchas for Extension Methods is that it's legal to call them on Null References. This isn't really surprising when you think about the feature. Boiled down to a fundamental level, extension methods are just syntactic sugar for calling a static method and automatically passing the first parameter...
30 Nov 2007
Extension Methods without 3.5 Framework
For a time I've been avoiding extension methods. Not because I'm opposed to using them but because of the 3.5 Framework. A lot of the tools I own are designed to be very light weight tools that only require the user to have 2.0 installed on their machine. I find that the easier that tools are to install...
16 Nov 2007
Page 1 of 1 (5 items)
© 2015 Microsoft Corporation.
Privacy & Cookies