23 writes to CurrentStage
Microsoft.Interop.SourceGeneration (23)
GeneratedStatements.cs (18)
36Setup = GenerateStatementsForStubContext(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.Setup }), 37Marshal = GenerateStatementsForStubContext(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.Marshal }), 38Pin = GenerateStatementsForStubContext(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.Pin }).Cast<FixedStatementSyntax>().ToImmutableArray(), 39PinnedMarshal = GenerateStatementsForStubContext(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.PinnedMarshal }), 41ErrorUnmarshalCapture = GenerateStatementsForStubContext(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.UnmarshalCapture }, errorHandlingOnly: true), 42ErrorUnmarshal = GenerateStatementsForStubContext(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.Unmarshal }, errorHandlingOnly: true), 43Unmarshal = GenerateStatementsForStubContext(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.UnmarshalCapture }) 44.AddRange(GenerateStatementsForStubContext(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.Unmarshal })), 45NotifyForSuccessfulInvoke = GenerateStatementsForStubContext(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.NotifyForSuccessfulInvoke }), 46GuaranteedUnmarshal = GenerateStatementsForStubContext(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.GuaranteedUnmarshal }), 47ErrorCleanupCalleeAllocated = GenerateStatementsForStubContext(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.CleanupCalleeAllocated }, errorHandlingOnly: true), 48CleanupCallerAllocated = GenerateStatementsForStubContext(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.CleanupCallerAllocated }), 49CleanupCalleeAllocated = GenerateStatementsForStubContext(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.CleanupCalleeAllocated }), 62InvokeStatement = GenerateStatementForNativeInvoke(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.Invoke }, expressionToInvoke) 69InvokeStatement = GenerateStatementForManagedInvoke(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.Invoke }, expressionToInvoke) 95InvokeStatement = GenerateStatementForProperty(marshallers, context with { CurrentStage = StubIdentifierContext.Stage.Invoke }, propertyAccess, isSetter) 237managedExceptionMarshaller.Generate(context with { CurrentStage = StubIdentifierContext.Stage.Marshal })); 239managedExceptionMarshaller.Generate(context with { CurrentStage = StubIdentifierContext.Stage.PinnedMarshal }));
Marshalling\ElementsMarshalling.cs (3)
488CurrentStage = StubIdentifierContext.Stage.Setup, 507var elementIdentifierContext = identifierContext with { CurrentStage = stage }; 517elementStatements.InsertRange(0, elementMarshaller.Generate(identifierContext with { CurrentStage = StubIdentifierContext.Stage.Setup }));
Marshalling\GenericFriendlyPointerIdentifierContext.cs (1)
22CurrentStage = inner.CurrentStage;
Marshalling\UnmanagedToManagedOwnershipTrackingStrategy.cs (1)
188CurrentStage = innerContext.CurrentStage;
37 references to CurrentStage
Microsoft.Interop.ComInterfaceGenerator (6)
Marshallers\ComInterfaceDispatchMarshallingResolver.cs (1)
42if (context.CurrentStage != StubIdentifierContext.Stage.Unmarshal)
Marshallers\KeepAliveThisMarshaller.cs (1)
20if (context.CurrentStage != StubIdentifierContext.Stage.NotifyForSuccessfulInvoke)
Marshallers\ManagedHResultExceptionGeneratorResolver.cs (2)
43if (context.CurrentStage != StubIdentifierContext.Stage.Unmarshal) 77if (context.CurrentStage != StubIdentifierContext.Stage.Unmarshal)
Marshallers\ObjectUnwrapperResolver.cs (1)
38if (context.CurrentStage != StubIdentifierContext.Stage.Unmarshal)
Marshallers\StructAsHResultMarshallerFactory.cs (1)
36switch (context.CurrentStage)
Microsoft.Interop.JavaScript.JSImportGenerator (12)
Marshaling\BaseJSGenerator.cs (1)
40if (context.CurrentStage == StubIdentifierContext.Stage.Setup
Marshaling\FuncJSGenerator.cs (4)
30if (context.CurrentStage == StubIdentifierContext.Stage.UnmarshalCapture && CodeContext.Direction == MarshalDirection.ManagedToUnmanaged && TypeInfo.IsManagedReturnPosition) 35if (context.CurrentStage == StubIdentifierContext.Stage.Marshal && CodeContext.Direction == MarshalDirection.UnmanagedToManaged && TypeInfo.IsManagedReturnPosition) 40if (context.CurrentStage == StubIdentifierContext.Stage.PinnedMarshal && CodeContext.Direction == MarshalDirection.ManagedToUnmanaged && !TypeInfo.IsManagedReturnPosition) 45if (context.CurrentStage == StubIdentifierContext.Stage.Unmarshal && CodeContext.Direction == MarshalDirection.UnmanagedToManaged && !TypeInfo.IsManagedReturnPosition)
Marshaling\ImplicitArgumentGenerator.cs (1)
19if (context.CurrentStage == StubIdentifierContext.Stage.Setup)
Marshaling\PrimitiveJSGenerator.cs (2)
26if (context.CurrentStage == StubIdentifierContext.Stage.UnmarshalCapture && marshalDirection is MarshalDirection.UnmanagedToManaged or MarshalDirection.Bidirectional) 31if (context.CurrentStage == StubIdentifierContext.Stage.Marshal && marshalDirection is MarshalDirection.ManagedToUnmanaged or MarshalDirection.Bidirectional)
Marshaling\TaskJSGenerator.cs (4)
25if (context.CurrentStage == StubIdentifierContext.Stage.UnmarshalCapture && CodeContext.Direction == MarshalDirection.ManagedToUnmanaged && TypeInfo.IsManagedReturnPosition) 32if (context.CurrentStage == StubIdentifierContext.Stage.Marshal && CodeContext.Direction == MarshalDirection.UnmanagedToManaged && TypeInfo.IsManagedReturnPosition) 39if (context.CurrentStage == StubIdentifierContext.Stage.PinnedMarshal && CodeContext.Direction == MarshalDirection.ManagedToUnmanaged && !TypeInfo.IsManagedReturnPosition) 46if (context.CurrentStage == StubIdentifierContext.Stage.Unmarshal && CodeContext.Direction == MarshalDirection.UnmanagedToManaged && !TypeInfo.IsManagedReturnPosition)
Microsoft.Interop.SourceGeneration (19)
GeneratedStatements.cs (5)
107if (context.CurrentStage is 122SyntaxTriviaList newLeadingTrivia = GenerateStageTrivia(context.CurrentStage); 132if (context.CurrentStage != StubIdentifierContext.Stage.Invoke) 166if (context.CurrentStage != StubIdentifierContext.Stage.Invoke) 193if (context.CurrentStage != StubIdentifierContext.Stage.Invoke)
Marshalling\BlittableMarshaller.cs (2)
46if (context.CurrentStage == StubIdentifierContext.Stage.Pin) 67switch (context.CurrentStage)
Marshalling\BoolMarshaller.cs (1)
54switch (context.CurrentStage)
Marshalling\CharMarshaller.cs (2)
53if (context.CurrentStage == StubIdentifierContext.Stage.Pin) 84switch (context.CurrentStage)
Marshalling\CustomTypeMarshallingGenerator.cs (1)
31switch (context.CurrentStage)
Marshalling\DelegateMarshaller.cs (1)
34switch (context.CurrentStage)
Marshalling\ElementsMarshalling.cs (1)
384context.CurrentStage);
Marshalling\GenericFriendlyPointerIdentifierContext.cs (1)
22CurrentStage = inner.CurrentStage;
Marshalling\IidParameterIndexMarshallerResolver.cs (1)
41if (context.CurrentStage != StubIdentifierContext.Stage.Marshal)
Marshalling\StaticPinnableManagedValueMarshaller.cs (1)
74if (context.CurrentStage == StubIdentifierContext.Stage.Pin)
Marshalling\UnmanagedToManagedOwnershipTrackingStrategy.cs (3)
151if (context.CurrentStage == StubIdentifierContext.Stage.Setup) 156if (context.CurrentStage == StubIdentifierContext.Stage.CleanupCallerAllocated) 188CurrentStage = innerContext.CurrentStage;