File tree Expand file tree Collapse file tree 2 files changed +15
-0
lines changed
src/tests/Loader/classloader/InlineArray Expand file tree Collapse file tree 2 files changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -26,6 +26,10 @@ public static void Explicit_Fails()
2626 public static void ExplicitSize_Fails ( )
2727 {
2828 Console . WriteLine ( $ "{ nameof ( ExplicitSize_Fails ) } ...") ;
29+
30+ // .size is ignored for auto layout
31+ Assert . Equal ( true , sizeof ( ExplicitSizeAuto ) > 0 ) ;
32+
2933 Assert . Throws < TypeLoadException > ( ( ) => { var t = typeof ( ExplicitSize ) ; } ) ;
3034
3135 Assert . Throws < TypeLoadException > ( ( ) =>
Original file line number Diff line number Diff line change 2525 .field [0] public valuetype [System.Runtime]System.Guid Guid
2626}
2727
28+ .class public auto ansi sealed beforefieldinit ExplicitSizeAuto
29+ extends [System.Runtime]System.ValueType
30+ {
31+ .custom instance void [System.Runtime]System.Runtime.CompilerServices.InlineArrayAttribute::.ctor(int32) = (
32+ 01 00 01 00 00 00 00 00
33+ )
34+
35+ .size 256
36+ .field [0] public valuetype [System.Runtime]System.Guid Guid
37+ }
38+
2839.class public sequential ansi sealed beforefieldinit ZeroLength
2940 extends [System.Runtime]System.ValueType
3041{
You can’t perform that action at this time.
0 commit comments