@@ -961,7 +961,7 @@ CSMethod CompileEnumFactory (EnumDeclaration enumDecl, EnumElement element, stri
961961 // {
962962 // EnumType retval = new Parameter();
963963 // unsafe {
964- // fixed (byte *retvalSwiftDataPtr = StructMarshal.Marshaler.PrepareNominal (this)) {
964+ // fixed (byte *retvalSwiftDataPtr = StructMarshal.Marshaler.PrepareValueType (this)) {
965965 // Pinvoke.ToSwift(new IntPtr(retvalSwiftDataPtr));
966966 // }
967967 // }
@@ -972,7 +972,7 @@ CSMethod CompileEnumFactory (EnumDeclaration enumDecl, EnumElement element, stri
972972 // {
973973 // EnumType retval = new Parameter()
974974 // unsafe {
975- // fixed (byte *retvalSwiftDataPtr = StructMarshal.Marshaler.PrepareNominal (this)) {
975+ // fixed (byte *retvalSwiftDataPtr = StructMarshal.Marshaler.PrepareValueType (this)) {
976976 // // marshal code for value
977977 // Pinvoke.ToSwift(new IntPtr(retvalSwiftDataPtr), whateverMarshaledValueIs);
978978 // }
@@ -1034,7 +1034,7 @@ void CompileEnumPayload(CSClass cl, EnumDeclaration enumDecl, EnumElement elemen
10341034 // throw new ArgumentOutOfRangeException("Expected Case to be Optional.");
10351035 // // marshaling for return type
10361036 // unsafe {
1037- // fixed (byte *thisSwiftDataPtr = StructMarshal.Marshaler.PrepareNominal (this)) {
1037+ // fixed (byte *thisSwiftDataPtr = StructMarshal.Marshaler.PrepareValueType (this)) {
10381038 // Pinvoke.ToSwift(..., new IntPtr(thisSwiftDataPtr));
10391039 // // more marshaling
10401040 // return value;
@@ -1905,7 +1905,7 @@ CSClass CompileVirtualClass (ClassDeclaration classDecl, ModuleInventory modInve
19051905
19061906 string className = StubbedClassName ( swiftClassName ) ;
19071907 use . AddIfNotPresent ( "SwiftRuntimeLibrary" ) ;
1908- use . AddIfNotPresent ( typeof ( SwiftNominalTypeAttribute ) ) ;
1908+ use . AddIfNotPresent ( typeof ( SwiftValueTypeAttribute ) ) ;
19091909
19101910 var cl = new CSClass ( CSVisibility . Public , className , null ) ;
19111911 CSAttribute . FromAttr ( typeof ( SwiftNativeObjectAttribute ) , new CSArgumentList ( ) , true ) . AttachBefore ( cl ) ;
@@ -3050,7 +3050,7 @@ CSClass CompileFinalClass (ClassDeclaration classDecl, ModuleInventory modInvent
30503050
30513051 string className = StubbedClassName ( swiftClassName ) ;
30523052 use . AddIfNotPresent ( "SwiftRuntimeLibrary" ) ;
3053- use . AddIfNotPresent ( typeof ( SwiftNominalTypeAttribute ) ) ;
3053+ use . AddIfNotPresent ( typeof ( SwiftValueTypeAttribute ) ) ;
30543054
30553055
30563056 var cl = new CSClass ( CSVisibility . Public , className , null ) ;
@@ -3521,7 +3521,7 @@ void ImplementObjCClassField (CSClass cl)
35213521
35223522 void ImplementMTFields ( CSClass cl , CSUsingPackages use )
35233523 {
3524- use . AddIfNotPresent ( typeof ( SwiftNominalTypeAttribute ) ) ;
3524+ use . AddIfNotPresent ( typeof ( SwiftValueTypeAttribute ) ) ;
35253525 cl . Fields . Add ( CSFieldDeclaration . FieldLine ( CSSimpleType . IntPtr , kHandleField , null ,
35263526 CSVisibility . Protected ) ) ;
35273527 use . AddIfNotPresent ( typeof ( SwiftMetatype ) ) ;
@@ -4002,14 +4002,14 @@ IEnumerable<CSMethod> MakeStructConstructors (CSClass st, CSClass picl, List<str
40024002 CSMethod NominalDefaultConstructor ( CSType structType , ClassContents classContents , CSUsingPackages use )
40034003 {
40044004 var parms = new CSParameterList ( ) ;
4005- use . AddIfNotPresent ( typeof ( SwiftNominalCtorArgument ) ) ;
4006- parms . Add ( new CSParameter ( new CSSimpleType ( typeof ( SwiftNominalCtorArgument ) ) , "unused" ) ) ;
4005+ use . AddIfNotPresent ( typeof ( SwiftValueTypeCtorArgument ) ) ;
4006+ parms . Add ( new CSParameter ( new CSSimpleType ( typeof ( SwiftValueTypeCtorArgument ) ) , "unused" ) ) ;
40074007 var body = new CSCodeBlock ( ) ;
40084008
40094009 string consName = StubbedClassName ( classContents . Name ) ;
40104010
40114011 var ctor = new CSMethod ( CSVisibility . Internal , CSMethodKind . None , null , new CSIdentifier ( consName ) , parms , body ) ;
4012- body . Add ( CSFunctionCall . FunctionCallLine ( "StructMarshal.Marshaler.PrepareNominal " , false , CSIdentifier . This ) ) ;
4012+ body . Add ( CSFunctionCall . FunctionCallLine ( "StructMarshal.Marshaler.PrepareValueType " , false , CSIdentifier . This ) ) ;
40134013
40144014 return ctor ;
40154015 }
@@ -6230,7 +6230,7 @@ static CSAttribute MakeNominalTypeAttribute (string library, string nominalSym,
62306230 al . Add ( new CSArgument ( CSConstant . Val ( library ) ) ) ;
62316231 al . Add ( new CSArgument ( CSConstant . Val ( nominalSym ) ) ) ;
62326232 al . Add ( new CSArgument ( CSConstant . Val ( metaSym ) ) ) ;
6233- return CSAttribute . FromAttr ( typeof ( SwiftNominalTypeAttribute ) , al , true ) ;
6233+ return CSAttribute . FromAttr ( typeof ( SwiftValueTypeAttribute ) , al , true ) ;
62346234 }
62356235
62366236 static CSAttribute MakeSwiftStructTypeAttribute ( string library , string nominalSym , string metaSym , string witnessSym )
0 commit comments