Exemplo n.º 1
0
        public void VisitExp(DB_Type type, DB_Member member, DB_StatementSyntax statement, MethodExp exp, Exp outer)
        {
            foreach (var a in exp.Args)
            {
                model.VisitExp(this, type, member, statement, a, exp);
            }
            if (exp.Caller is IndifierExp)
            {
            }
            else
            {
                model.VisitExp(this, type, member, statement, exp.Caller, exp);
            }

            DB_Type returnType = model.GetExpType(exp);

            if (returnType != null)
            {
                typeRef.Add(returnType.GetRefType());
            }
        }
Exemplo n.º 2
0
        public void VisitExp(DB_Type type, DB_Member member, DB_StatementSyntax statement, FieldExp exp, Exp outer)
        {
            DB_Type caller = model.GetExpType(exp.Caller);

            typeRef.Add(caller.GetRefType());


            if (caller.members.ContainsKey(exp.Name))
            {
                typeRef.Add(caller.members[exp.Name].typeName);
            }
            //else
            //{
            //    List<DB_Member> methods = caller.FindMethod(exp.Name, model);
            //    if(methods.Count>0)
            //    {
            //        //typeRef.Add(caller.members[exp.Name].typeName);
            //    }
            //}


            model.VisitExp(this, type, member, statement, exp.Caller, exp);
        }
Exemplo n.º 3
0
 public void VisitExp(DB_Type type, DB_Member member, DB_StatementSyntax statement, ThisExp exp, Exp outer)
 {
     typeRef.Add(type.GetRefType());
 }