Files
2025-10-25 03:02:53 +03:00

1.2 KiB

[stmt.expr]

8 Statements [stmt]

8.3 Expression statement [stmt.expr]

1

#

Expression statements have the form

expression-statement:
expressionopt ;

The expression is a discarded-value expression.

Allside effects from an expression statement are completed before the next statement is executed.

An expression statement with the expression missing is called a null statement.

[Note 1:

Most statements are expression statements — usually assignments or function calls.

A null statement is useful to supply a null body to an iteration statement such as a while statement ([stmt.while]).

— end note]