"Jeroen Frijters" <[EMAIL PROTECTED]> writes: > It could do that, but it probably isn't worthwhile. The C# language > specification requires that a NullReferenceException is thrown when x is > null, callvirt does this check, but call doesn't so that is why, in > general, callvirt should be used. In this particular case, the compiler > could see that x is always non-null, but it probably isn't worthwhile to > optimize for this.
The problem here is that we do not track this in mcs's definite assignment checks: MCS checks whether `x' has been assigned (which it must be), but it doesn't know which value `x' has because it could have been initialized to `null'. -- Martin Baulig [EMAIL PROTECTED] _______________________________________________ Mono-list maillist - [EMAIL PROTECTED] http://lists.ximian.com/mailman/listinfo/mono-list
