4 ms·
If you view the comma and semicolon as separators instead of terminators it works much better. It is also what they really are. A semicolon separates two claus
by rvirding 16y ago
If you view the comma and semicolon as separators instead of terminators it works much better. It is also what they really are.
A semicolon separates two clauses, either two if/case/receive clauses or two function clauses and means or. Either choose the first clause or the clause following the semicolon. An if/case/receive is terminated with an 'end' while a function is terminated with a dot.
Fred Hebert, the author of Learn You Some Erlang, wrote this on syntax: http://ferd.ca/on-erlang-s-syntax.html http://ferd.ca/on-erlang-s-syntax.html