| Liste des Groupes | Revenir à cl c |
David Brown <david.brown@hesbynett.no> writes:Agreed (I also agree on the correction of terminology).
[...]In C, an expression statement "expr;" causes the expression to be[...]
evaluated as a void expression for its side effects (§6.8.4p2). You
can, arguably, say that C also requires all statements to be of "void"
type, just like Pascal - but the cast-to-void is done implicitly to
treat "expr;" as "(void) expr;".
In an expression statement, the expression is "evaluated as a void
expression for its side effects". I think that's equivalent to
convert (not casting!) it to void, but the standard doesn't describe
it that way.
6.3.2.2: "If an expression of any other type [other than void]Correct.
is evaluated as a void expression, its value or designator is
discarded."
But statements have no type.
Les messages affichés proviennent d'usenet.