pike.git / lib / modules / Simulate.pmod

version» Context lines:

pike.git/lib/modules/Simulate.pmod:1:   inherit Array;   inherit Stdio;   inherit String;   inherit Process;      #define error(X) throw( ({ (X), backtrace()[0..sizeof(backtrace())-2] }) )    - inherit Regexp : regexp; -  +    varargs int member_array(mixed needle,mixed *haystack,int start)   {    return search(haystack,needle,start);   }      object previous_object()   {    int e;    mixed **trace;    object o,ret;
pike.git/lib/modules/Simulate.pmod:37:   function get_function(object o, string a)   {    mixed ret;    ret=o[a];    return functionp(ret) ? ret : 0;   }      string *map_regexp(string *s, string reg)   {    -  regexp::create(reg); -  s=filter(s,regexp::match); -  regexp::create(); /* Free compiled regexp */ +  object(Regexp) regexp = Regexp(reg); +  s=filter(s,regexp->match);    return s;   }      constant PI = 3.1415926535897932384626433832795080;   function all_efuns = all_constants;   function explode = `/;   function filter_array = filter;   function map_array = map;   function implode = `*;   function m_indices = indices;