Jon Jagger
jon@jaggersoft.com
Table of Contents 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 Notes DownloadECMA-334 C# Language Specificationpreviousnextprevious at this levelnext at this level 25 Unsafe codeprevious at this levelnext at this level 25.5 Pointers in expressionsprevious at this levelnext at this level 25.5.5 Pointer increment and decrement Paragraph 11 In an unsafe context, the ++ and --operators (§14.5.9 and §14.6.5) can be applied to pointer variables of all types except void*. 2 Thus, for every pointer type T*, the following operators are implicitly defined:
T* operator ++(T* x);  
T* operator --(T* x);  
Paragraph 21 The operators produce the same results as x+1 and x-1, respectively (§25.5.6). 2 In other words, for a pointer variable of type T*, the ++ operator adds sizeof(T) to the address contained in the variable, and the --operator subtracts sizeof(T) from the address contained in the variable. Paragraph 31 If a pointer increment or decrement operation overflows the domain of the pointer type, the result is implementation-defined, but no exceptions are produced.
{ JSL }
Jagger Software Ltd
Company # 4070126
VAT # 762 5213 42
Valid HTML 4.01Valid CSS