Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] at_exit functions not called during exit
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Warp <warplayer@f...>
Subject: Re: [Caml-list] at_exit functions not called during exit
> I noticed that functions registered with Pervasives.at_exit are
> not called when a C-library function calls exit. Is this a bug or
> a feature?

If you call the exit() C function in your C-library, it'll exit regardless
you're using OCaml or any other feature.
BTW, Pervasives.at_exit seems to be only called when an unhandled exception
reach the top-level.

Warp

-------------------
Bug reports: http://caml.inria.fr/bin/caml-bugs  FAQ: http://caml.inria.fr/FAQ/
To unsubscribe, mail caml-list-request@inria.fr  Archives: http://caml.inria.fr