pike.git / lib / modules / Thread.pmod

version» Context lines:

pike.git/lib/modules/Thread.pmod:1:   constant Mutex=__builtin.mutex;   constant Condition=__builtin.condition;      class Fifo {    inherit Condition : r_cond; -  inherit Condition: w_cond; -  inherit Mutex: lock; +  inherit Condition : w_cond; +  inherit Mutex : lock;       array buffer;    int ptr, num;    int read_tres, write_tres;       int size() { return num; }       mixed read()    {    mixed tmp;
pike.git/lib/modules/Thread.pmod:67:    }       void create(int|void size)    {    write_tres=0;    buffer=allocate(read_tres=size || 128);    }   };      class Queue { -  inherit Condition: r_cond; -  inherit Mutex: lock; +  inherit Condition : r_cond; +  inherit Mutex : lock;       mixed *buffer=allocate(16);    int r_ptr, w_ptr;       int size() { return w_ptr - r_ptr; }       mixed read()    {    mixed tmp;    object key=lock::lock();