Version française
Home     About     Download     Resources     Contact us    
Browse thread
Why doesn't ocamlopt detect a missing ; after failwith statement?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Richard Jones <rich@a...>
Subject: Re: [Caml-list] Why doesn't ocamlopt detect a missing ; after failwith statement?
Thanks everyone for the explanation, and the rather convoluted
discussion of the type system, which I don't really understand.

I'd just like to add that this error bit me in a real program, and it
would be nice if OCaml detected this common case and warned about it:

  if cond then (
    ...
    raise Exn
  )
  next_stmt       <-- catastrophic failure, because this statement
                      is silently ignored

Rich.

-- 
Richard Jones.  http://www.annexia.org/  http://www.j-london.com/
>>>   http://www.team-notepad.com/ - collaboration tools for teams   <<<
Merjis Ltd. http://www.merjis.com/ - improving website return on investment
http://youunlimited.co.uk/ - Personal improvement courses