Exemplo n.º 1
0
        Expression Lookup(EvaluationContext context, FrameHandle frame)
        {
            string[] namespaces = context.GetNamespaces (frame);
            if (namespaces == null)
                return null;

            foreach (string ns in namespaces) {
                string full_name = MakeFQN (ns, name);
                Expression expr = LookupMember (context, frame, full_name);
                if (expr != null)
                    return expr;
            }

            return null;
        }
Exemplo n.º 2
0
        protected override Expression DoResolveType(EvaluationContext context)
        {
            FrameHandle frame = context.CurrentFrame;
            ITargetType type = frame.Language.LookupType (frame.Frame, name);
            if (type != null)
                return new TypeExpression (type);

            string[] namespaces = context.GetNamespaces (frame);
            if (namespaces == null)
                return null;

            foreach (string ns in namespaces) {
                string full_name = MakeFQN (ns, name);
                type = frame.Language.LookupType (frame.Frame, full_name);
                if (type != null)
                    return new TypeExpression (type);
            }

            return null;
        }