ocamlsdl, exceptions not registered
Hi,
This problem has been discussed yet some time ago on the main ocaml mailing
list:
https://sympa.inria.fr/sympa/arc/caml-list/2010-03/msg00154.html
The problem is that the ocamlsdl exceptions are not registered.
It has been explained that it was not an ocamlsdl bug, but a bug in ocaml.
But still, ocamlsdl users have to use some workaround for this, otherwise we
just get:
exception not registered.Abandon
I still use in my project the workaround that I provide in joint piece.
Even if it's an ocaml bug, don't you think that we should try to do something?
- We could include a workaround in ocamlsdl itself, so that users don't have
to care about this issue.
- We could provide an equivalent sdlfix.ml in ocamlsdl that is not really part
of ocamlsdl but that users could copy in their projects and that users could
use until ocaml is fixed.
- Or at least if we do nothing, maybe we could write in some readme file
something to inform users of the issue and how to work around it.
Please tell-me what you think.
--
let init () =
Callback.register_exception "SDL_init_exception" (Sdl.SDL_init_exception "");
Callback.register_exception "sdlevent_exn" (Sdlevent.Event_exn "");
Callback.register_exception "SDLvideo2_exception" (Sdlvideo.Video_exn "");
Callback.register_exception "SDLjoystick_exception" (Sdljoystick.SDLjoystick_exception "");
;;
Reply to: