public void Test1(SomeClassWithOneConstructor obj) { Contract.Requires(obj != null); var str = obj.TheString_AsMethodCall(); // we should infer the postcondition Contract.Assert(str != null); // no warning }
public void Test0(SomeClassWithOneConstructor obj) { Contract.Requires(obj != null); var str = obj.TheString; Contract.Assert(str != null); // no warning }