1 implementation of TypeInfo
Microsoft.Interop.JavaScript.JSImportGenerator (1)
Marshaling\BaseJSGenerator.cs (1)
24public TypePositionInfo TypeInfo => _inner.TypeInfo;
53 references to TypeInfo
Microsoft.Interop.ComInterfaceGenerator (1)
UnmanagedToManagedStubGenerator.cs (1)
103allStatements.Add(ReturnStatement(IdentifierName(_context.GetIdentifiers(_marshallers.NativeReturnMarshaller.TypeInfo).native)));
Microsoft.Interop.JavaScript.JSImportGenerator (12)
JSExportCodeGenerator.cs (7)
54if (_marshallers.ManagedReturnMarshaller.TypeInfo.MarshallingAttributeInfo is JSMarshallingInfo(_, JSTaskTypeInfo)) 56IBoundMarshallingGenerator spanArg = _marshallers.SignatureMarshallers.FirstOrDefault(m => m.TypeInfo.MarshallingAttributeInfo is JSMarshallingInfo(_, JSSpanTypeInfo)); 59diagnosticsBag.ReportGeneratorDiagnostic(new GeneratorDiagnostic.NotSupported(spanArg.TypeInfo) 179statementsToUpdate.Add(LocalDeclarationStatement(VariableDeclaration(marshaller.TypeInfo.ManagedType.Syntax) 180.WithVariables(SingletonSeparatedList(VariableDeclarator(marshaller.TypeInfo.InstanceIdentifier))))); 206arguments.Add(Argument(IdentifierName(marshaller.TypeInfo.InstanceIdentifier))); 219(string _, string nativeIdentifier) = _context.GetIdentifiers(_marshallers.ManagedReturnMarshaller.TypeInfo);
JSImportCodeGenerator.cs (4)
61if (_marshallers.ManagedReturnMarshaller.TypeInfo.MarshallingAttributeInfo is JSMarshallingInfo(_, JSTaskTypeInfo)) 63IBoundMarshallingGenerator spanArg = _marshallers.SignatureMarshallers.FirstOrDefault(m => m.TypeInfo.MarshallingAttributeInfo is JSMarshallingInfo(_, JSSpanTypeInfo)); 66diagnosticsBag.ReportGeneratorDiagnostic(new GeneratorDiagnostic.NotSupported(spanArg.TypeInfo) 130allStatements.Add(ReturnStatement(IdentifierName(_context.GetIdentifiers(_marshallers.ManagedReturnMarshaller.TypeInfo).managed)));
Marshaling\BaseJSGenerator.cs (1)
24public TypePositionInfo TypeInfo => _inner.TypeInfo;
Microsoft.Interop.SourceGeneration (40)
BoundGenerators.cs (9)
70managedParamMarshallers.Sort(static (m1, m2) => m1.TypeInfo.ManagedIndex.CompareTo(m2.TypeInfo.ManagedIndex)); 71nativeParamMarshallers.Sort(static (m1, m2) => m1.TypeInfo.NativeIndex.CompareTo(m2.TypeInfo.NativeIndex)); 120static m => GetInfoIndex(m.TypeInfo), 121static m => GetInfoDependencies(m.TypeInfo)) 185public bool ManagedNativeSameReturn => ManagedReturnMarshaller.TypeInfo.IsNativeReturnPosition; 187public bool IsManagedVoidReturn => ManagedReturnMarshaller.TypeInfo.ManagedType == SpecialTypeInfo.Void; 189public bool IsUnmanagedVoidReturn => NativeReturnMarshaller.TypeInfo.ManagedType == SpecialTypeInfo.Void;
GeneratedStatements.cs (5)
106if (marshallers.NativeReturnMarshaller.TypeInfo.ManagedType == SpecialTypeInfo.Void) 111var (managed, native) = context.GetIdentifiers(marshallers.NativeReturnMarshaller.TypeInfo); 140if (marshallers.ManagedReturnMarshaller.TypeInfo.ManagedType == SpecialTypeInfo.Void) 148IdentifierName(context.GetIdentifiers(marshallers.ManagedReturnMarshaller.TypeInfo).managed), 162var (managed, _) = context.GetIdentifiers(managedExceptionMarshaller.TypeInfo);
ManagedToNativeStubGenerator.cs (3)
84noMarshallingNeeded &= (generator.IsBlittable() && !generator.TypeInfo.IsByRef) || generator.IsForwarder(); 88HasForwardedTypes |= generator.IsForwarder() && generator is { TypeInfo.ManagedType: not SpecialTypeInfo { SpecialType: Microsoft.CodeAnalysis.SpecialType.System_Void } }; 191allStatements.Add(ReturnStatement(IdentifierName(_context.GetIdentifiers(_marshallers.ManagedReturnMarshaller.TypeInfo).managed)));
Marshalling\ByValueContentsMarshalKindValidator.cs (2)
37var support = generator.Generator.SupportsByValueMarshalKind(generator.Generator.TypeInfo.ByValueContentsMarshalKind, out GeneratorDiagnostic? diagnostic); 42ByValueMarshalKindSupport.NotSupported => ResolvedGenerator.ResolvedWithDiagnostics(s_forwarder.Bind(generator.Generator.TypeInfo, context), generator.Diagnostics.Add(diagnostic!)),
Marshalling\MarshallingGeneratorExtensions.cs (11)
24SignatureBehavior.ManagedTypeAndAttributes => generator.TypeInfo.ManagedType.Syntax, 43if (generator.TypeInfo.MarshallingAttributeInfo is IForwardedMarshallingInfo forwarded 64return GenerateForwardingParameter(generator.TypeInfo, context.GetIdentifiers(generator.TypeInfo).managed); 71identifierName = context.GetIdentifiers(generator.TypeInfo).native; 81(string managed, string native) = context.GetIdentifiers(generator.TypeInfo); 82string param = context.GetAdditionalIdentifier(generator.TypeInfo, ParameterIdentifierSuffix); 85ValueBoundaryBehavior.ManagedIdentifier => generator.TypeInfo.IsByRef ? param : managed, 141TypePositionInfo info = generator.TypeInfo; 156TypePositionInfo info = generator.TypeInfo; 167TypePositionInfo info = generator.TypeInfo;
VariableDeclarations.cs (10)
23TypePositionInfo info = marshaller.TypeInfo; 57(string managed, string native) = context.GetIdentifiers(marshaller.TypeInfo); 60if (marshaller.TypeInfo.IsManagedReturnPosition || marshaller.TypeInfo.IsNativeReturnPosition) 63marshaller.TypeInfo.ManagedType.Syntax, 86TypePositionInfo info = marshaller.TypeInfo; 114(string managed, string native) = context.GetIdentifiers(marshaller.TypeInfo); 117if (marshaller.TypeInfo.IsNativeReturnPosition) 123marshaller.TypeInfo.ManagedType.Syntax, 170marshaller.TypeInfo.ManagedType.Syntax,