[erlang-questions] Order of evaluation of guards
Wed Jan 7 00:44:35 CET 2015
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.
More information about the erlang-questions