Ejemplo n.º 1
0
        public static (MemberKindVisitor, MemberKindLookup) Make(WhoDefinedMemberByMethodlike extensionLookup, IProject <Assembly, object> project)
        {
            MemberKindLookup lookup = new MemberKindLookup();
            //
            // TODO
            // we can add project.DependencyScope directly to the lookups
            // this doesn't really need to happen in here, the MemberKindVisitor isn't involved at all
            // but it is a nessisray part of the flow
            //foreach (var member in project.DependencyScope.Members) {
            //    lookup.AddDependency(xxx, member);
            //}

            var res = new MemberKindVisitor(new List <IOrType <IEntryPointDefinition, IImplementationDefinition, IInternalMethodDefinition, IRootScope> >()
            {
            }, lookup, extensionLookup);

            //res.Init();
            return(res, lookup);
        }
Ejemplo n.º 2
0
 private MemberKindVisitor(IReadOnlyList <IOrType <IEntryPointDefinition, IImplementationDefinition, IInternalMethodDefinition, IRootScope> > stack, MemberKindLookup lookup, WhoDefinedMemberByMethodlike extensionLookup)
 {
     this.stack           = stack ?? throw new ArgumentNullException(nameof(stack));
     this.lookup          = lookup ?? throw new ArgumentNullException(nameof(lookup));
     this.extensionLookup = extensionLookup ?? throw new ArgumentNullException(nameof(extensionLookup));
 }