12.3.3.20 General rules for expressions with embedded expressions

王朝other·作者佚名  2006-01-10
窄屏简体版  字體: |||超大  

12.3.3.20 General rules for expressions with embedded expressions

The following rules apply to these kinds of expressions: parenthesized

expressions (?4.5.3), element access

expressions (?4.5.6), base access expressions with indexing (?4.5.8),

increment and decrement

expressions (?4.5.9, ?4.6.5), cast expressions (?4.6.6), unary +, -, ~,

* expressions, binary +, -, *, /, %,

<<, >>, <, <=, >, >=, ==, !=, is, as, &, |, ^ expressions (?4.7, ?4.8, ?4.

9, ?4.10), compound

Chapter 12 Variables

109

assignment expressions (?4.13.2), checked and unchecked expressions (?4.5.1

2), array and delegate

creation expressions (?4.5.10).

Each of these expressions has one or more sub-expressions that are

unconditionally evaluated in a fixed

order. [Example: For example, the binary % operator evaluates the left hand

side of the operator, then the

right hand side. An indexing operation evaluates the indexed expression,

and then evaluates each of the

index expressions, in order from left to right. end example] For an

expression expr, which has subexpressions

expr1, expr2, ..., exprn, evaluated in that order:

?The definite assignment state of v at the beginning of expr1 is the same

as the definite assignment

state at the beginning of expr.

?The definite assignment state of v at the beginning of expri (i greater

than one) is the same as the

definite assignment state at the end of expri-1.

?The definite assignment state of v at the end of expr is the same as the

definite assignment state at

the end of exprn.

 
 
 
免责声明:本文为网络用户发布,其观点仅代表作者个人观点,与本站无关,本站仅提供信息存储服务。文中陈述内容未经本站证实,其真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
 
 
© 2005- 王朝網路 版權所有 導航