diff options
author | Julien Cretel <j.cretel@umail.ucc.ie> | 2015-06-16 18:14:36 +0100 |
---|---|---|
committer | Julien Cretel <j.cretel@umail.ucc.ie> | 2015-06-16 18:15:46 +0100 |
commit | 5f8c78bc9983ea23b624a3b82aed17c1cc4d4ebe (patch) | |
tree | d0786dfceaf4352577143201288e0875b26fd598 /erlang.html.markdown | |
parent | 1b4661ed384237832582d45e24e869f1f33c3076 (diff) |
[erlang/en] Fix #1142
Diffstat (limited to 'erlang.html.markdown')
-rw-r--r-- | erlang.html.markdown | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/erlang.html.markdown b/erlang.html.markdown index a3b571d1..8b67a76a 100644 --- a/erlang.html.markdown +++ b/erlang.html.markdown @@ -164,6 +164,13 @@ is_cat(A) -> false. is_dog(A) when is_atom(A), A =:= dog -> true; is_dog(A) -> false. +% We won't dwell on the `=:=` operator here; just be aware that it is used to +% check whether two Erlang expressions have the same value *and* the same type. +% Contrast this behaviour to that of the `==` operator: +1 + 2 =:= 3. % true +1 + 2 =:= 3.0. % false +1 + 2 == 3.0. % true + % A guard sequence is either a single guard or a series of guards, separated % by semicolons (`;`). The guard sequence `G1; G2; ...; Gn` is true if at % least one of the guards `G1`, `G2`, ..., `Gn` evaluates to `true`. |