Reflection and Nullable<T> are a bit of a pain; reflection uses object , and Nullable<T> has special box / unpack rules for object . Thus, by the time you have an object , it is no longer a Nullable<T> - it is either null or the value itself.
i.e.
int? a = 123, b = null; object c = a;
This is sometimes a little confusing and notices that you cannot get the original T from the empty Nullable<T> that was inserted into the box, since all you have is null .
Marc gravell
source share