Skip to content

Support C# 8.0 nullable reference types in model building #10347

@MarcoLoetscher

Description

@MarcoLoetscher

C# 8 is on the way and better to early than too late should be planned the implementation of the new features (Introducing Nullable Reference Types in C#).

public class Blog
{
    public int BlogId { get; set; }
    public string Url { get; set; } //In C# 8 this should be required by default
    public string? Url2 { get; set; } //In C# 8 this should be optional by default

    //Needs EF support for constructors with parameters
    public Blog(string url) 
    {
        Url = url;
    }
}

A new logic is needed for mapping of e. g. string: Required and Optional Properties

Support for constructors with Parameters is required: Flexible mapping to CLR types and members (Custom O/C Mapping #240)

This list is probably not complete.

Metadata

Metadata

Assignees

Labels

No labels
No labels
No fields configured for Feature.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions