Yaron Minsky yminsky@janestreet.com:
Interesting.  Anyone know if the disabling of 21 with strict-sequence
is a fundamental issue, or just an accident?  It seems best to have
both available at once.

This is most certainly an accident.
I should look into that.
(However preserving 21 would change some error messages too)

This said, I personally do not like the statement warning, and I'm not a big fan of
-strict-sequence either, as both require changes in APIs.
This said, I prefer the option to the warning: at least it gives strong guarantees.

Jacques 

On Mon, Oct 28, 2013 at 8:42 AM, ygrek <ygrek@autistici.org> wrote:
> Hello,
>
> I have one problem with this option. Basically - it disables warning 21. Consider:
>
> $ ocaml
>
> # let f () = exit 0; 1;;
> Characters 11-17:
>   let f () = exit 0; 1;;
>              ^^^^^^
> Warning 21: this statement never returns (or has an unsound type.)
> val f : unit -> int = <fun>
>
> $ ocaml -strict-sequence
>
> # let f () = exit 0; 1;;
> val f : unit -> int = <fun>
>
> So I choose to disable this option and strictly require `let () =` when calling callbacks.
>
> --
>
> --
> Caml-list mailing list.  Subscription management and archives:
> https://sympa.inria.fr/sympa/arc/caml-list
> Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
> Bug reports: http://caml.inria.fr/bin/caml-bugs

--
Caml-list mailing list.  Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
Bug reports: http://caml.inria.fr/bin/caml-bugs