I'm trying to use a record with Unity3d. The documentation says C# 9 is now supported, but I still get the error:
The predefined type 'System.Runtime.CompilerServices.IsExternalInit' must be defined or imported in order to declare init-only setter.
The documentation states this, but I'm not sure what it means:
The type System.Runtime.CompilerServices.IsExternalInit is required for full record support as it uses init only setters, but is only available in .NET 5 and later (which Unity doesn’t support). Users can work around this issue by declaring the System.Runtime.CompilerServices.IsExternalInit type in their own projects.