[erlang-questions] Order of evaluation of guards
Wed Jan 7 11:45:51 CET 2015
> On 7 jan 2015, at 00:44, Anthony Ramine <n.oxyde@REDACTED> wrote:
> Le 6 janv. 2015 à 20:02, Robert Virding <rvirding@REDACTED> a écrit :
>> I think it is very important to stress that the guard and the body of a clause are very different beasts and obey different rules. Adding a proper 'cond' might help. All in IMAO.
> 'Cond' would help, indeed . Deprecating guard sequences in 'if' expressions too . :)
>> On 6 January 2015 at 19:25, Thomas Lindgren <thomasl_erlang@REDACTED> wrote:
>> Guards are a mess IMO, for reasons including, but not restricted to, the ones you mention.
> The award goes to erlang:float/1, messiest guard ever . I would like to see it deprecated (as other old type guards without the 'is' prefix) and the function to be renamed to integer_to_float/1.
I guess number_to_float/1 is more compatible with the old erlang:float/1 function ?
>  https://github.com/erlang/otp/pull/464
>  https://github.com/rebar/rebar/commit/2c4d7d1d9bdc2a11d3f485f844500bf4c2aa77a2
>  http://www.erlang.org/doc/man/erlang.html#float-1
> erlang-questions mailing list
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 801 bytes
Desc: Message signed with OpenPGP using GPGMail
More information about the erlang-questions