home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / lang / prolog / 1619 < prev    next >
Encoding:
Internet Message Format  |  1992-08-29  |  1.1 KB

  1. Path: sparky!uunet!cs.utexas.edu!sun-barr!sh.wide!wnoc-tyo-news!scslwide!socslgw!daemon
  2. From: kono@csl.sony.co.jp (Shinji Kono)
  3. Newsgroups: comp.lang.prolog
  4. Subject: Re: Pipes in Quintus
  5. Message-ID: <1992Aug29.011608.28340@nntp.csl.sony.co.jp>
  6. Date: 29 Aug 92 01:16:08 GMT
  7. References: <17ljnjINNlbo@swan.doc.ic.ac.uk>
  8. Sender: daemon@nntp.csl.sony.co.jp (The devil himself)
  9. Reply-To: kono@csl.sony.co.jp
  10. Organization: Sony Computer Science Laboratory, Inc.
  11. Lines: 17
  12.  
  13. In article <17ljnjINNlbo@swan.doc.ic.ac.uk> , 
  14.     jvp@doc.ic.ac.uk (Jeremy Pitt) writes 
  15. >Does anybody either (a) know of an easy way of doing both or (b) have
  16. >a library package which exports predicates to do this.
  17.  
  18. If you are using Sun, named pipe is an easy way to do it.
  19.      mknod p fifo
  20.      quintus
  21.      ?- unix(system('ls -l >>fifo &')).
  22.      ?- see(fifo),repeat,get0(X),put(X),X = -1,seen.
  23. Or it is not so difficult to write fork/exec system call interface.
  24.  
  25. You need some trick to get stderr/stdout separately in csh. (But I forget
  26. it :-)
  27. ---
  28. Shinji Kono @           kono@csl.sony.co.jp
  29. Sony Computer Science Laboratory, Inc,Japan
  30.