3 implementations of IMethodBody
Microsoft.CodeAnalysis (3)
CodeGen\MethodBody.cs (1)
16internal sealed class MethodBody : Cci.IMethodBody
Emit\NoPia\CommonEmbeddedMethod.cs (1)
112private sealed class EmptyBody : Cci.IMethodBody
PEWriter\RootModuleStaticConstructor.cs (1)
17internal sealed partial class RootModuleStaticConstructor : IMethodDefinition, IMethodBody
68 references to IMethodBody
Microsoft.CodeAnalysis (68)
CodeGen\MethodBody.cs (14)
118ImmutableArray<SourceSpan> Cci.IMethodBody.CodeCoverageSpans => _codeCoverageSpans; 120ImmutableArray<Cci.ExceptionHandlerRegion> Cci.IMethodBody.ExceptionRegions => _exceptionHandlers; 122bool Cci.IMethodBody.AreLocalsZeroed => _areLocalsZeroed; 124ImmutableArray<Cci.ILocalDefinition> Cci.IMethodBody.LocalVariables => _locals; 126Cci.IMethodDefinition Cci.IMethodBody.MethodDefinition => _parent; 128StateMachineMoveNextBodyDebugInfo Cci.IMethodBody.MoveNextBodyInfo => _stateMachineMoveNextDebugInfoOpt; 130ushort Cci.IMethodBody.MaxStack => _maxStack; 136ImmutableArray<Cci.LocalScope> Cci.IMethodBody.LocalScopes => _localScopes; 141Cci.IImportScope Cci.IMethodBody.ImportScope => _importScopeOpt; 143string Cci.IMethodBody.StateMachineTypeName => _stateMachineTypeNameOpt; 145ImmutableArray<StateMachineHoistedLocalScope> Cci.IMethodBody.StateMachineHoistedLocalScopes 148ImmutableArray<EncHoistedLocalInfo> Cci.IMethodBody.StateMachineHoistedLocalSlots 151ImmutableArray<Cci.ITypeReference?> Cci.IMethodBody.StateMachineAwaiterSlots 154bool Cci.IMethodBody.HasDynamicLocalVariables => _hasDynamicLocalVariables;
Emit\CommonPEModuleBuilder.cs (5)
37private readonly ConcurrentDictionary<IMethodSymbolInternal, Cci.IMethodBody> _methodBodyMap; 66_methodBodyMap = new ConcurrentDictionary<IMethodSymbolInternal, Cci.IMethodBody>(ReferenceEqualityComparer.Instance); 327internal Cci.IMethodBody? GetMethodBody(IMethodSymbolInternal methodSymbol) 333Cci.IMethodBody? body; 344public void SetMethodBody(IMethodSymbolInternal methodSymbol, Cci.IMethodBody body)
Emit\EditAndContinue\DeletedMethodBody.cs (1)
14internal sealed class DeletedMethodBody(IDeletedMethodDefinition methodDef, ImmutableArray<byte> il) : Cci.IMethodBody
Emit\EditAndContinue\DeletedPEMethodDefinition.cs (1)
89public Cci.IMethodBody GetBody(EmitContext context)
Emit\EditAndContinue\DeletedSourceMethodDefinition.cs (1)
111public IMethodBody GetBody(EmitContext context)
Emit\EditAndContinue\DeltaMetadataWriter.cs (1)
852protected override StandaloneSignatureHandle SerializeLocalVariablesSignature(IMethodBody body)
Emit\NoPia\CommonEmbeddedMethod.cs (21)
99Cci.IMethodBody? Cci.IMethodDefinition.GetBody(EmitContext context) 121ImmutableArray<Cci.ExceptionHandlerRegion> Cci.IMethodBody.ExceptionRegions => 124bool Cci.IMethodBody.HasStackalloc => false; 126bool Cci.IMethodBody.AreLocalsZeroed => false; 128ImmutableArray<Cci.ILocalDefinition> Cci.IMethodBody.LocalVariables => 131Cci.IMethodDefinition Cci.IMethodBody.MethodDefinition => _method; 133ushort Cci.IMethodBody.MaxStack => 0; 135ImmutableArray<byte> Cci.IMethodBody.IL => ImmutableArray<byte>.Empty; 137ImmutableArray<Cci.SequencePoint> Cci.IMethodBody.SequencePoints => ImmutableArray<Cci.SequencePoint>.Empty; 139bool Cci.IMethodBody.HasDynamicLocalVariables => false; 141StateMachineMoveNextBodyDebugInfo Cci.IMethodBody.MoveNextBodyInfo => null; 143ImmutableArray<SourceSpan> Cci.IMethodBody.CodeCoverageSpans => ImmutableArray<SourceSpan>.Empty; 145ImmutableArray<Cci.LocalScope> Cci.IMethodBody.LocalScopes => 148Cci.IImportScope Cci.IMethodBody.ImportScope => null; 150ImmutableArray<StateMachineHoistedLocalScope> Cci.IMethodBody.StateMachineHoistedLocalScopes => 153string Cci.IMethodBody.StateMachineTypeName => null; 155ImmutableArray<EncHoistedLocalInfo> Cci.IMethodBody.StateMachineHoistedLocalSlots => 158ImmutableArray<Cci.ITypeReference> Cci.IMethodBody.StateMachineAwaiterSlots => 161ImmutableArray<EncClosureInfo> Cci.IMethodBody.ClosureDebugInfo => 164ImmutableArray<EncLambdaInfo> Cci.IMethodBody.LambdaDebugInfo => 167ImmutableArray<LambdaRuntimeRudeEditInfo> Cci.IMethodBody.OrderedLambdaRuntimeRudeEdits =>
Emit\NoPia\VtblGap.cs (1)
28Cci.IMethodBody? Cci.IMethodDefinition.GetBody(EmitContext context)
NativePdbWriter\PdbWriter.cs (2)
66public void SerializeDebugInfo(IMethodBody methodBody, StandaloneSignatureHandle localSignatureHandleOpt, CustomDebugInfoWriter customDebugInfoWriter) 157private void DefineNamespaceScopes(IMethodBody methodBody)
PEWriter\CustomDebugInfoWriter.cs (9)
24private IMethodBody _methodBodyWithModuleInfo; 27private IMethodBody _previousMethodBodyWithUsingInfo; 42public bool ShouldForwardNamespaceScopes(EmitContext context, IMethodBody methodBody, MethodDefinitionHandle methodHandle, out IMethodDefinition forwardToMethod) 68IMethodBody methodBody, 165IMethodBody methodBody, 203private static void SerializeDynamicLocalInfo(ref CustomDebugInfoEncoder encoder, IMethodBody methodBody) 245private static void SerializeTupleElementNames(ref CustomDebugInfoEncoder encoder, IMethodBody methodBody) 262private void SerializeNamespaceScopeMetadata(ref CustomDebugInfoEncoder encoder, EmitContext context, IMethodBody methodBody) 291private bool ShouldForwardToPreviousMethodWithUsingInfo(EmitContext context, IMethodBody methodBody)
PEWriter\Members.cs (1)
528IMethodBody? GetBody(EmitContext context);
PEWriter\MetadataVisitor.cs (1)
262public virtual void Visit(IMethodBody methodBody)
PEWriter\MetadataWriter.cs (4)
2955IMethodBody body; 2996private int SerializeMethodBody(MethodBodyStreamEncoder encoder, IMethodBody methodBody, StandaloneSignatureHandle localSignatureHandleOpt, ref UserStringHandle mvidStringHandle, ref Blob mvidStringFixup) 3041protected virtual StandaloneSignatureHandle SerializeLocalVariablesSignature(IMethodBody body) 4151internal static EditAndContinueMethodDebugInformation GetEncMethodDebugInfo(IMethodBody methodBody)
PEWriter\MetadataWriter.DynamicAnalysis.cs (1)
66internal void SerializeMethodCodeCoverageData(IMethodBody? body)
PEWriter\MetadataWriter.PortablePdb.cs (3)
57private void SerializeMethodDebugInfo(IMethodBody bodyOpt, int methodRid, int aggregateMethodRid, StandaloneSignatureHandle localSignatureHandleOpt, ref LocalVariableHandle lastLocalVariableHandle, ref LocalConstantHandle lastLocalConstantHandle) 600private void SerializeStateMachineLocalScopes(IMethodBody methodBody, MethodDefinitionHandle method) 806private void SerializeEncMethodDebugInformation(IMethodBody methodBody, MethodDefinitionHandle method)
PEWriter\ReferenceIndexer.cs (1)
108var body = method.GetBody(Context);
PEWriter\RootModuleStaticConstructor.cs (1)
35public IMethodBody GetBody(EmitContext context) => this;