+4  A: 

I believe it's because IX is an interface. The compiler thinks that maybe a value of type IX could already be derived from Wrapped<IX> (even if Wrapped<T> is sealed) so it doesn't use the conversion.

The details are quite complicated, in sections 6.4.3 and 6.4.4 of the C# 3.0 spec. Basically because IX is an interface, it's not "encompassed by" any types, which means a later step in 6.4.4 fails.

I suggest you create a non-generic type Wrapped with this method:

public static Wrapped<T> Of<T>(T item)
{
    return new Wrapped<T>(item);
}

Then you can just write:

using (Wrapped<IX> wrappedIX = Wrapped.Of(plainIX))

Basically conversions can be a bit tricky for various reasons - simple methods are generally easier to understand, IMO.

Jon Skeet
This will work with C#4, when `T` is properly decorated with `out`, or doesn't it work for implicit casting?
Dykam
@Dykam: You're assuming that `T` *can* be used covariantly. I'm also not sure what you mean by "this" - but as the type of `plainIX` is `IX` rather than `X`, I don't believe the original code would work out of the box.
Jon Skeet
Hmm, indeed. Then I missed that part. Implicit conversions get messy quickly in any case.
Dykam