mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2024-12-24 10:01:38 +00:00
Replaced 'or' with a semicolons
Replaced 'or' with a semicolons since the paragraph above is talking about using semicolons
This commit is contained in:
parent
9e4274f7c7
commit
5a62ebbc85
@ -177,7 +177,7 @@ is_dog(A) -> false.
|
|||||||
% A guard sequence is either a single guard or a series of guards, separated
|
% 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
|
% by semicolons (`;`). The guard sequence `G1; G2; ...; Gn` is true if at
|
||||||
% least one of the guards `G1`, `G2`, ..., `Gn` evaluates to `true`.
|
% least one of the guards `G1`, `G2`, ..., `Gn` evaluates to `true`.
|
||||||
is_pet(A) when is_atom(A), (A =:= dog) or (A =:= cat) -> true;
|
is_pet(A) when is_atom(A), (A =:= dog);(A =:= cat) -> true;
|
||||||
is_pet(A) -> false.
|
is_pet(A) -> false.
|
||||||
|
|
||||||
% Warning: not all valid Erlang expressions can be used as guard expressions;
|
% Warning: not all valid Erlang expressions can be used as guard expressions;
|
||||||
|
Loading…
Reference in New Issue
Block a user