pike.git / lib / master.pike.in

version» Context lines:

pike.git/lib/master.pike.in:1: - /* $Id: master.pike.in,v 1.33 1998/10/16 18:38:32 grubba Exp $ + /* $Id: master.pike.in,v 1.34 1998/10/17 02:10:00 grubba Exp $    *    * Master-file for Pike.    *    * Based on master.pike 1.67.    */      // Some configurable parameters useful for debugging      // Used by describe_backtrace() et al.   #if !defined(BT_MAX_STRING_LEN) || (BT_MAX_STRING_LEN <= 0)
pike.git/lib/master.pike.in:521:    {    joined_modules = _joined_modules;    }       object|mapping ind(string index)    {    array(mixed) res = ({});    foreach(joined_modules, object|mapping o) {    mixed ret;    if (!zero_type(ret = o[index])) { +  if (objectp(ret = o[index]) && +  (< joinnode, dirnode >)[object_program(ret)]) { +  // Only join directorynodes (or joinnodes).    res += ({ ret }); -  +  } else if (!sizeof(res)) { +  return(ret); +  } else { +  // Ignore +  werror(sprintf("Ignoring index %s: %t\n", index, ret)); +  continue;    }    } -  +  }    if (sizeof(res) > 1) {    return joinnode(res);    } else if (sizeof(res)) {    return res[0];    }    return UNDEFINED;    }       object|mapping `[](string index)    {
pike.git/lib/master.pike.in:625:    return fc[path]=dirnode(path);   }      mixed resolv(string identifier, string|void current_file)   {    array(mixed) tmp = ({});    foreach(pike_module_path, string path)    {    string file=combine_path(path,identifier);    if(mixed ret=findmodule(file)) { +  if ((objectp(ret)) && +  (< joinnode, dirnode >)[object_program(ret)]) {    if (mixed new_ret = ret->_module_value) {    ret = new_ret;    }    tmp += ({ ret }); -  +  } else { +  if (mixed new_ret = ret->_module_value) { +  ret = new_ret;    } -  +  if (!sizeof(tmp)) { +  return ret; +  } else { +  // Ignore +  werror(sprintf("Ignoring file %O: %t for identifier %O\n", +  file, ret, identifier)); +  continue;    } -  +  } +  } +  }    if (sizeof(tmp)) {    if (sizeof(tmp) == 1) {    return(tmp[0]);    }    return joinnode(tmp);    }    return UNDEFINED;   }      // These are useful if you want to start other Pike processes