On Sun, 11 May 2003 05:45:24 +0900, Brian Candler wrote:

> If you want your C++ program directly to open pipes and fork() and exec()
> children, then of course you will get into OS-specific issues, especially
> where Windows doesn't follow POSIX. But that's a C++ programming problem.
> Presumably one of the advantages of embedding Ruby is that you can delegate
> those sort of tasks to it.

Agree.. missing standardization sux.. but then again  how should people
gain access to extra features and innovation ? 

 
>> > In general, if I wanted to run some program which interacted over
>> > stdin/stdout, but I wanted that interaction to occur inside a GUI window, I
>> > would create a window, fork and exec a child, and talk to it over pipes, so
>> > that I could capture keystrokes and send them down stdin, and capture stdout
>> > and stick it on the screen as it was generated.
>> 
>> Remember that im sharing classes with those programs (c++ <=> ruby),
>> marshalling it over a pipe would be slow (but I have no evidence here). 
>> What you talking about is a ruby-jail ;-)
> 
> It's two different execution models:

Exactly.. choose either the red or the blue pill.


Thanks, This has been an good discussion.  You keep reminding me of those
things which I assume to be trivial, which is NOT trivial for others.. 
If you hadn't reminded me, I would totaly forgot to write it into the
tutorial.

Futher more I didn't know anything about unix-pipes before. And now I have
done several experiments.

--
Simon Strandgaard