Expression statement (Definition)

Expressions do not necessarily have to be placed on the right of an assignment operator.

Availability:

ECMAScript edition - 2

An expression statement is an expression that is evaluated on a line by itself.

Expression statements consist of a stand-alone expression followed by a semi-colon (;).

An example of the main use of expressions in this context would be a function call. Since a function is a named block of code that can be called by putting its identifier into an expression, a function that does not return a value or where the value has been voided is being called like a procedure or sub-routine in other languages.

See also:Constant expression, Semi-colon (;), Statement

Cross-references:

ECMA 262 edition 2 - section - 12.4

ECMA 262 edition 3 - section - 12.4

Wrox Instant JavaScript - page - 18