Syndication

News

     

Archives

Miscelaneous

Programming

January 2009 - Posts

Due to a bug in VS intellisense (go vote for it!), my otherwise nice approach to API evolution doesn't quite work as I expected. Basically, regardless of whether you flag your obsolete methods (extension methods created by moving the deprecated behavior into a new "Legacy.dll" assembly) with EditorBrowsableState.Never, they will still show up in intellisense. You typically don't want that, as it would confuse users of test projects that contain legacy tests about which methods should be used:

image

A side effect of the approach in ...

Read full article

Posted by Daniel Cazzulino
Filed under: ,

API evolution is tough and versioning is a complex enough issue that deserves not one but several posts. So I will only focus on one specific kind of evolution and backwards compatibility: Source Compatibility.

Let's say you have a class with a given functionality:

public class Mock
{
    public void VerifyAll()
    {
        // ...
    }
}

At a certain point, let's say you realize it was not such a good idea to have that method, and would rather have people using another method by default, but still being able to opt-in to the "old" behavior. One way of achieving this is to move this method to a new assembly (i.e. MyProduct.Legacy.dll), as an extension method:...

Read full article

Posted by Daniel Cazzulino
Filed under: ,
More Posts