3 Jul 00:12
Re: Future [exec] overhaul
From: Larry McVoy <lm@...>
Subject: Re: Future [exec] overhaul
Newsgroups: gmane.comp.lang.tcl.core
Date: 2008-07-02 22:12:51 GMT
Subject: Re: Future [exec] overhaul
Newsgroups: gmane.comp.lang.tcl.core
Date: 2008-07-02 22:12:51 GMT
On Thu, Jul 03, 2008 at 12:04:02AM +0200, Alexandre Ferrieux wrote: > Hmm, a "portable" [system] could spawn /bin/sh -c in unix and cmd /c > in winblows... But I admit this is so trivial to do in script that it > is off-topic for this discussion. You really don't want to do cmd /c, the two shells are way too different. What we did is make a fair amount of the shell parsing be internal so that we could spawn pipelines, redirect files, etc. We were also careful to spot and barf on shell constructs we didn't support. For our needs, it's been great. And better perf than going through sh. > So, I'll accept any name you want for this. Now to the semantics. Any > other ideas, or criticism of the ones I proposed ? I didn't look at all of them carefully but the approach of creating a system() like interface is very nice. In tcl, I'd ask for a way that you could do set stdout [system echo $foo] We have a backtick() api that does that for us. Quite pleasant. -- -- --- Larry McVoy lm at bitmover.com http://www.bitkeeper.com ------------------------------------------------------------------------- Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW! Studies have shown that voting for your favorite open source project, along with a healthy diet, reduces your potential for chronic lameness and boredom. Vote Now at http://www.sourceforge.net/community/cca08
RSS Feed