I'm porting the LINQ provider of Signum Framework to .Net 5, In general I'm quite happy with the not nullable annotations, but I found two rough corners:
|
public MethodCallExpression Update(Expression @object, IEnumerable<Expression>? arguments) |
public MethodCallExpression Update(Expression @object, IEnumerable<Expression>? arguments)
public MethodCallExpression Update(Expression? @object, IEnumerable<Expression>? arguments) //Inconsistent: The member is optional, but the Update method is not.
|
public ConstructorInfo? Constructor { get; } |
public ConstructorInfo? Constructor { get; }
public ConstructorInfo Constructor { get; } //I think the constructor is mandatory, otherwise the Type property will throw exception.
I'm porting the LINQ provider of Signum Framework to .Net 5, In general I'm quite happy with the not nullable annotations, but I found two rough corners:
runtime/src/libraries/System.Linq.Expressions/src/System/Linq/Expressions/MethodCallExpression.cs
Line 62 in 6072e4d
runtime/src/libraries/System.Linq.Expressions/src/System/Linq/Expressions/NewExpression.cs
Line 43 in 6072e4d