Пример #1
0
/* SRC: classes/exception.php line 152 */
void c_Exception::t_inittrace() {
  INSTANCE_METHOD_INJECTION_BUILTIN(Exception, Exception::initTrace);
  Variant v_top;
  Variant v_frame;

  ObjectData *obj_tmp UNUSED;
  {
    const CallInfo *cit0 = NULL;
    MethodCallPackage mcp0;
    mcp0.staticMethodCall(NAMSTR(s_sys_ssf08d205d, "static"), NAMSTR(s_sys_ssc453e9e9, "getTraceOptions"));
    mcp0.lateStaticBind(fi.getThreadInfo());
    cit0 = mcp0.ci;
    const Array &tmp1((x_debug_backtrace(toBoolean((cit0->getMeth0Args())(mcp0, 0)))));
    m_trace = tmp1;
  }
  LOOP_COUNTER(1);
  {
    while (!(empty(m_trace))) {
      LOOP_COUNTER_CHECK(1);
      {
        {
          const Variant &tmp0((m_trace.rvalAt(0LL, AccessFlags::Error)));
          v_top.assignVal(tmp0);
        }
        {
          bool tmp0;
          {
            bool tmp1 = ((isset(v_top, NAMSTR(s_sys_ssc82dbd12, "class"), true) && isset(v_top, NAMSTR(s_sys_ss52403931, "function"), true)));
            if (tmp1) {
              const String &tmp2((toString(v_top.rvalAt(NAMSTR(s_sys_ssc82dbd12, "class"), AccessFlags::Error_Key))));
              int64 tmp3((x_strcasecmp(tmp2, NAMSTR(s_sys_ssae8717ad, "exception"))));
              tmp1 = (same(tmp3, 0LL));
            }
            bool tmp4 = (tmp1);
            if (tmp4) {
              const String &tmp5((toString(v_top.rvalAt(NAMSTR(s_sys_ss52403931, "function"), AccessFlags::Error_Key))));
              int64 tmp6((x_strcasecmp(tmp5, NAMSTR(s_sys_ssa26bedd7, "__init__"))));
              tmp4 = (same(tmp6, 0LL));
            }
            tmp0 = (tmp4);
          }
          if (tmp0) {
            {
              {
                const Variant &tmp0((x_array_shift(ref(m_trace))));
                v_frame.assignVal(tmp0);
              }
              if (isset(v_frame, NAMSTR(s_sys_ss8ce7db5b, "file"), true)) {
                {
                  const Variant &tmp0((v_frame.rvalAt(NAMSTR(s_sys_ss8ce7db5b, "file"), AccessFlags::Error_Key)));
                  m_file.assignVal(tmp0);
                }
              }
              if (isset(v_frame, NAMSTR(s_sys_ssddf8728c, "line"), true)) {
                {
                  const Variant &tmp0((v_frame.rvalAt(NAMSTR(s_sys_ssddf8728c, "line"), AccessFlags::Error_Key)));
                  m_line.assignVal(tmp0);
                }
              }
              return;
            }
          }
        }
        x_array_shift(ref(m_trace));
      }
    }
  }
}
Пример #2
0
/* SRC: classes/exception.php line 25 */
void c_Exception::t___init__() {
  INSTANCE_METHOD_INJECTION_BUILTIN(Exception, Exception::__init__);
  Variant v_top;
  Variant v_frame;

  ObjectData *obj_tmp UNUSED;
  if (toBoolean(m_inited)) {
    {
      return;
    }
  }
  m_inited = true;
  {
    const Array &tmp0((x_debug_backtrace(false)));
    m_trace = tmp0;
  }
  LOOP_COUNTER(1);
  {
    while (!(empty(m_trace))) {
      LOOP_COUNTER_CHECK(1);
      {
        {
          const Variant &tmp0((m_trace.rvalAt(0LL, AccessFlags::Error)));
          v_top.assignVal(tmp0);
        }
        {
          bool tmp0;
          {
            bool tmp1 = (empty(v_top, NAMSTR(s_sys_ssc82dbd12, "class"), true));
            if (!tmp1) {
              const String &tmp2((toString(v_top.rvalAt(NAMSTR(s_sys_ss52403931, "function"), AccessFlags::Error_Key))));
              bool tmp3 = (toBoolean(x_strcasecmp(tmp2, NAMSTR(s_sys_ssa26bedd7, "__init__"))));
              if (tmp3) {
                const String &tmp4((toString(v_top.rvalAt(NAMSTR(s_sys_ss52403931, "function"), AccessFlags::Error_Key))));
                tmp3 = (toBoolean(x_strcasecmp(tmp4, NAMSTR(s_sys_ssa1b87da7, "__construct"))));
              }
              bool tmp5 = (tmp3);
              if (tmp5) {
                const String &tmp6((toString(v_top.rvalAt(NAMSTR(s_sys_ss52403931, "function"), AccessFlags::Error_Key))));
                const String &tmp7((toString(v_top.rvalAt(NAMSTR(s_sys_ssc82dbd12, "class"), AccessFlags::Error_Key))));
                tmp5 = (toBoolean(x_strcasecmp(tmp6, tmp7)));
              }
              tmp1 = (tmp5);
            }
            bool tmp8 = (tmp1);
            if (!tmp8) {
              const String &tmp9((toString(v_top.rvalAt(NAMSTR(s_sys_ssc82dbd12, "class"), AccessFlags::Error_Key))));
              bool tmp10 = (toBoolean(x_strcasecmp(tmp9, NAMSTR(s_sys_ssae8717ad, "exception"))));
              if (tmp10) {
                const Variant &tmp11((v_top.rvalAt(NAMSTR(s_sys_ssc82dbd12, "class"), AccessFlags::Error_Key)));
                tmp10 = (!(x_is_subclass_of(tmp11, NAMSTR(s_sys_ssae8717ad, "exception"))));
              }
              tmp8 = (tmp10);
            }
            tmp0 = (tmp8);
          }
          if (tmp0) {
            {
              break;
            }
          }
        }
        {
          const Variant &tmp0((x_array_shift(ref(m_trace))));
          v_frame.assignVal(tmp0);
        }
      }
    }
  }
  if (isset(v_frame, NAMSTR(s_sys_ss8ce7db5b, "file"), true)) {
    {
      const Variant &tmp0((v_frame.rvalAt(NAMSTR(s_sys_ss8ce7db5b, "file"), AccessFlags::Error_Key)));
      m_file.assignVal(tmp0);
    }
  }
  if (isset(v_frame, NAMSTR(s_sys_ssddf8728c, "line"), true)) {
    {
      const Variant &tmp0((v_frame.rvalAt(NAMSTR(s_sys_ssddf8728c, "line"), AccessFlags::Error_Key)));
      m_line.assignVal(tmp0);
    }
  }
}