home *** CD-ROM | disk | FTP | other *** search
/ QBasic & Borland Pascal & C / Delphi5.iso / C / Samples / COPROC.ARJ / COPROC.H < prev   
Encoding:
C/C++ Source or Header  |  1993-03-02  |  653 b   |  34 lines

  1. /**/
  2. /*
  3. /*      coproc.h
  4. /*
  5. /*      (C) Copyright by Serge Babkin, 1993
  6. /*
  7. /*      Any part of this code may be freely distributed for
  8. /*      the non-commertial use when it contains this copyright
  9. /*      notice only.
  10. /*
  11. /*      My FIDO address is: 2:5010/4
  12. /*
  13. /**/
  14.  
  15. #ifndef _COPROC_H
  16.  
  17. #define _COPROC_H
  18.  
  19. extern int lbolt;
  20.  
  21. int cosleep();
  22. int cofork();
  23. int run1coproc();
  24. int cowakeup();
  25. int coexit();
  26. int cogetpid();
  27.  
  28. /* switch to the next coprocess, insert the current coprocess */
  29. /* into the ready-to-run queue with priority pri              */
  30.  
  31. #define coswtch(pri)      cosleep(&lbolt,pri)
  32.  
  33. #endif /* _COPROC_H */
  34.