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 11 Typesprevious at this levelnext at this level 11.1 Value types Paragraph 11 A value type is either a struct type or an enumeration type. 2 C# provides a set of predefined struct types called the simple types. 3 The simple types are identified through reserved words. value-type : struct-type enum-type struct-type : type-name simple-type simple-type : numeric-type bool numeric-type : integral-type floating-point-type decimal integral-type : sbyte byte short ushort int uint long ulong char floating-point-type : float double enum-type : type-name Paragraph 21 All value types implicitly inherit from class object. 2 It is not possible for any type to derive from a value type, and value types are thus implicitly sealed (§17.1.1.2). Paragraph 31 A variable of a value type always contains a value of that type. 2 Unlike reference types, it is not possible for a value of a value type to be null, or to reference an object of a more derived type. Paragraph 41 Assignment to a variable of a value type creates a copy of the value being assigned. 2 This differs from assignment to a variable of a reference type, which copies the reference but not the object identified by the reference.
{ JSL }
Jagger Software Ltd
Company # 4070126
VAT # 762 5213 42
Valid HTML 4.01Valid CSS