Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] Checked exceptions and type inference
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Xavier Leroy <xavier.leroy@i...>
Subject: Re: [Caml-list] Checked exceptions and type inference
> Is there any research on using checked exceptions in an ML derived 
> language?  Any plans/opinions on implementing checked exceptions in Ocaml?

As Jacques mentioned, you can look at François Pessaux's work, e.g.
our TOPLAS article

Briefly, Java-style exception declarations just don't work with
higher-order functions and parametric polymorphism.  For ML, you need
row polymorphism on the exception declarations to achieve sufficient
precision, and the resulting types are complicated enough that you
don't want to write them in module interfaces.  The solution François
explored is to infer completely these exception annotations with a
whole-program analysis.

- Xavier Leroy

To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: