[erlang-questions] When to return {ok, Value} or just the Value

Richard Carlsson carlsson.richard@REDACTED
Thu Nov 17 11:49:10 CET 2011


On 11/17/2011 12:07 AM, Steve Davis wrote:
> Probably just me, but "case catch()" seems more natural in erlang than
> "try... catch", (much for the same reasons that I prefer a case
> statement to the weird "if" in erlang which IMHO should also be
> removed to avoid pollution).

Your choice, of course, but do read 
http://www.erlang.se/workshop/2004/exception.pdf to understand the 
limitations of the plain old catch. It conflates a whole lot of information.

    /Richard



More information about the erlang-questions mailing list