English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
getting more information on_exit
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2005-02-17 (21:17)
From: Yaron Minsky <yminsky@g...>
Subject: getting more information on_exit
Does anyone know if it's possible to get more information from the
on_exit call?  Right now, the on_exit call just gets unit.  It would
be useful, for example, to get the exit code.  That would allow one to
distinguish between an ordinary exit and an exceptional one.

The context in which I'm looking at this is ocamlmpi.  Right now,
ocamlmpi calls the MPI finalize function on exit.  This is all well
and good in normal situations, but when an unexpected exception is
thrown, it would be better to call the abort function.  If I could
distinguish between different kinds of exits, this would be easy to