internal void GetCustomDebugInfos(SymbolMethodImpl symMethod, MethodDef method, CilBody body, IList <PdbCustomDebugInfo> result)
 {
     Debug.Assert(method.Module == module);
     GetCustomDebugInfos(method.MDToken.ToInt32(), GenericParamContext.Create(method), result, method, body, out var asyncStepInfo);
     if (asyncStepInfo is not null)
     {
         var asyncMethod = TryCreateAsyncMethod(module, symMethod.KickoffMethod, asyncStepInfo.AsyncStepInfos, asyncStepInfo.CatchHandler);
         Debug.Assert(asyncMethod is not null);
         if (asyncMethod is not null)
         {
             result.Add(asyncMethod);
         }
     }
     else if (symMethod.KickoffMethod != 0)
     {
         var iteratorMethod = TryCreateIteratorMethod(module, symMethod.KickoffMethod);
         Debug.Assert(iteratorMethod is not null);
         if (iteratorMethod is not null)
         {
             result.Add(iteratorMethod);
         }
     }
 }
        public override SymbolMethod GetMethod(MethodDef method, int version)
        {
            if (version != 1)
            {
                return(null);
            }
            var  mdTable   = pdbMetadata.TablesStream.MethodDebugInformationTable;
            uint methodRid = method.Rid;

            if (!mdTable.IsValidRID(methodRid))
            {
                return(null);
            }

            var sequencePoints = ReadSequencePoints(methodRid) ?? Array2.Empty <SymbolSequencePoint>();
            var gpContext      = GenericParamContext.Create(method);
            var rootScope      = ReadScope(methodRid, gpContext);

            var kickoffMethod = GetKickoffMethod(methodRid);
            var symbolMethod  = new SymbolMethodImpl(this, method.MDToken.ToInt32(), rootScope, sequencePoints, kickoffMethod);

            rootScope.method = symbolMethod;
            return(symbolMethod);
        }