Ejemplo n.º 1
0
 internal void CALLSTATIC(string name)
 {
     if (name.Contains('.'))
     {
         try
         {
             string[] cn = name.Split('.');
             vClass   c  = GetClass(cn[0]);
             vMethod  m  = c.getMethod(name.Substring(name.IndexOf('.') + 1));
             vCall    ca = new vCall();
             ca.referance    = m;
             ca.retaddress   = instructionIndex;
             ca.startaddress = m.GetAddress();
             callstack.Push(ca);
             ca.Run(this);
         }
         catch
         {
         }
     }
     else
     {
         vMethod m = GetMethod(name);
         if (m != null)
         {
             vCall c = new vCall();
             c.startaddress = m.GetAddress();
             c.retaddress   = instructionIndex;
             c.referance    = m;
             callstack.Push(c);
             c.Run(this);
         }
         else
         {
             parent.Error("Method not found!", "Could not find method: " + name + " in global method list.");
         }
     }
 }