A.7.10 Equality Operators

The == (equal to) and the != (not equal to) operators are analogous to the relational operators except for their lower precedence. (Thus a<b == c<d is 1 whenever a<b and c<d have the same truth-value.)

The equality operators follow the same rules as the relational operators, but permit additional possibilities: a pointer may be compared to a constant integral expression with value 0, or to a pointer to void. See Par.A.6.6.

TCPL/A.07.10_Equality_Operators (2008-02-23 15:34:07由localhost编辑)

ch3n2k.com | Copyright (c) 2004-2020 czk.