On Fri, Sep 29, 2006 at 00:39:21 -0400, Magnus Jonsson wrote:
> >1) It adds some new exit codes for internal usage, paraphrasing the 
> >comments,
> >     -1 for fork() failure
> >     -2 for pipe(),
> >     -3 execvp_no_vtalarm()
> >   Dut does this mean we're counting on the programs themselves never
> >   exiting with these codes?
> 
> exec_extern returns process id of the newly launched child process, or one 
> of those error codes if it fails. There used to be no/little error 
> checking here.

Oops! I just realised in the shower that those were process ids you were
returning, not exit codes.  (Which makes questions 1 and 2 rather
nonsensical; sorry about that).

> doesn't carry with it any exit code, because no program was run.
> 
> >3) I'm a bit nervous about catching ExitFailure at main - it seems like
> >  this is something we would want to bubble up.  How do you know this
> >  doesn't misreport ExitFailures thrown by darcs itself?
> 
> It is better than the current status I think - right now these failures 
> pass unseen and if here is a failure, the desired side effects never take 
> place. This way darcs realizes that there's a problem and bails out. Darcs
> itself shouldn't throw any ExecFailure. Only Exec.hs should throw 
> ExecFailure.

Oh, I see; that is a new exception type _Exec_Failure, hence the
catchDyn, not ExitFailure, which for that matter probably doesn't even
exist (exitFailure).  Consider me less nervous.

A new question for you

5) Why use bug? This indicates that darcs itself is broken; is an
   ExecFailure an indication that darcs is broken?

All the best,

-- 
Eric Kow                     http://www.loria.fr/~kow
PGP Key ID: 08AC04F9         Merci de corriger mon français.

Attachment: pgpVs5HhmwWmk.pgp
Description: PGP signature

_______________________________________________
darcs-devel mailing list
[email protected]
http://www.abridgegame.org/cgi-bin/mailman/listinfo/darcs-devel

Reply via email to