Esempio n. 1
0
        protected override void AddLookupSymbolsInfoInSingleBinder(
            LookupSymbolsInfo result, LookupOptions options, Binder originalBinder)
        {
            // Add types within namespaces imported through usings, but don't add nested namespaces.
            LookupOptions usingOptions = (options & ~(LookupOptions.NamespaceAliasesOnly | LookupOptions.NamespacesOrTypesOnly)) | LookupOptions.MustNotBeNamespace;

            Imports.AddLookupSymbolsInfoInUsings(ConsolidatedUsings, this, result, usingOptions);
        }
Esempio n. 2
0
        protected override void AddLookupSymbolsInfoInSingleBinder(LookupSymbolsInfo result, LookupOptions options, Binder originalBinder)
        {
            this.AddMemberLookupSymbolsInfo(result, _container, options, originalBinder);

            // if we are looking only for labels we do not need to search through the imports
            if (!_container.IsSubmissionClass && ((options & LookupOptions.LabelsOnly) == 0))
            {
                var imports = GetImports(basesBeingResolved: null);

                imports.AddLookupSymbolsInfoInAliases(this, result, options);

                // Add types within namespaces imported through usings, but don't add nested namespaces.
                LookupOptions usingOptions = (options & ~(LookupOptions.NamespaceAliasesOnly | LookupOptions.NamespacesOrTypesOnly)) | LookupOptions.MustNotBeNamespace;
                Imports.AddLookupSymbolsInfoInUsings(imports.Usings, this, result, usingOptions);
            }
        }