- 21
- 0
- 约1.57万字
- 约 10页
- 2016-10-12 发布于贵州
- 举报
c_运算符先级和结合性
c/c++ 运算符的优先级和结合性ZZ
2010-05-18 15:29
Precedence Operator Description Example Associativity 1 ()[]-.::++-- Grouping operatorArray accessMember access from a pointerMember access from an objectScoping operatorPost-incrementPost-decrement (a + b) / 4;array[4] = 2;ptr-age = 34;obj.age = 34;Class::age = 2;for( i = 0; i 10; i++ ) ...for( i = 10; i 0; i-- ) ... left to right 2 !~++---+*(type)sizeof Logical negationBitwise complementPre-incrementPre-decrementUnary minusUnary plusDereferenceAddress ofCast to a given typeReturn size in bytes if( !done ) ...flags
原创力文档

文档评论(0)