Xamarin.SwiftUI
Xamarin.SwiftUI copied to clipboard
Adopt `LayoutKind.Explicit` for opaque structures
Previously, CoreCLR did not support explicit layout for structs on non-Windows platforms. To work around it, we ended up adding a bunch of dummy fields, such as this one, to make opaque structs the right size.
Now that explicit layout is supported, we should remove those dummy fields and pass LayoutKind.Explicit and the Size to the StructLayout attribute.