[erlang-questions] Keyword documentation

caio ariede caio.ariede@REDACTED
Fri Feb 19 19:10:43 CET 2010


What does "cond" and "let" do?

Caio Ariede
http://caioariede.com/


On Fri, Feb 19, 2010 at 2:46 PM, tsuraan <tsuraan@REDACTED> wrote:

> > The following are reserved words in Erlang:
>
> Ok, so assuming no definitive list of what they do exists, I guess
> I'll start one :)  These are either from the top of my head, or
> http://erlang.org/doc/reference_manual/expressions.html .  Any
> corrections, completions, clarifications are welcome.
>
> > after
> Sets the timeout in a receive block
>
> > and
> boolean logic "and"
>
> > andalso
> short-circuiting "and"
>
> > band
> bitwise "and"
>
> > begin
> Start a block, used for grouping expresssions (no idea what use it is)
>
> > bnot
> > bor
> bitwise "not" and "or"
>
> > bsl
> > bsr
> Shift bits left and right
>
> > bxor
> bitwise "xor"
>
> > case
> Beginning of a case statement, sort of like C's switch statement
>
> > catch
> Trap an error, converting it into the tuple {'EXIT', ...}.  If no
> error occurs, the result of the wrapped function is returned.  Also
> used in the try statement.
>
> > cond
> ?
>
> > div
> integer division
>
> > end
> Complete a statement (fun, case, try, etc).
>
> > fun
> Begin an anonymous function
>
> > if
> Erlang's crazy if statement.
>
> > let
> ?
>
> > not
> Logical "not"
>
> > of
> Goes between value of case statement and guard clauses
>
> > or
> Logical "or"
>
> > orelse
> Short-circuiting "or"
>
> > query
> Obsolete, something about mneosyne?
>
> > receive
> used to get the next message from the process mailbox
>
> > rem
> Remainder from integer division (modulus)
>
> > try
> New way to trap errors, used with catch and ends with end
>
> > when
> Start a guard sequence for receive, function declaration, others?
>
> > xor
> Logical xor
>
> ________________________________________________________________
> erlang-questions (at) erlang.org mailing list.
> See http://www.erlang.org/faq.html
> To unsubscribe; mailto:erlang-questions-unsubscribe@REDACTED
>
>


More information about the erlang-questions mailing list