Browse thread
[Caml-list] Checked exceptions and type inference
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ 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 http://pauillac.inria.fr/~xleroy/publi/exceptions-toplas.ps.gz 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 caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners