Đang chuẩn bị nút TẢI XUỐNG, xin hãy chờ
Tải xuống
Tham khảo tài liệu 'the new c standard- p3', công nghệ thông tin, kỹ thuật lập trình phục vụ nhu cầu học tập, nghiên cứu và làm việc hiệu quả | 3.17.1 74 Commentary For instance the bits making up an object could be interpreted as an integer value a pointer value or a 1352 dSClSlStiOn floating-point value. The definition of the type determines how the contents are to be interpreted. mterpretaton of S35 mtegei- A literal also has a value. Its type is determined by both the lexical form of the token and its numeric constant type first in list value. C The value representation of an object is the set of bits that hold the value of type T. 3.9p4 Coding Guidelines This definition separates the ideas of representation and value. A general principle behind many guidelines is 569.1 represen-thdl mdlrino iicp mI rAntAQAntQtiAn ic nnf r lQt AffAr tiwA T Iia Hpiaq nrAt TYt rwi lA mfinv tation in_ that making use of representation information is not cost effective. The c standard does not provide many formation guarantees that any representation is fixed in places it specifies that two representations are the same . using Example i include stdio.h 2 3 union 4 float mem_1 5 int mem_2 6 char mem_3 7 x 1.234567 8 9 int main void 10 11 12 Interpret the same bit pattern using various types. 13 The values output might be 1.234567 1067320907 0x3f9e064b 14 15 printf f d p n x.mem_1 x.mem_2 x.mem_3 16 3.17.1 74 implementation-defined value unspecified value where each implementation documents how the choice is made implementation-defined value Commentary Implementations are not required to document any unspecified value unless it has been specified as being implementation-defined. The semantic attribute denoted by an implementation-defined value might be applicable during translation e.g. FLT_EVAL_METHOD or only during program execution e.g. the values assigned to argv on program startup . 76 unspecified value 354 FLTEVALME 171 argv values C90 Although C90 specifies that implementation-defined values occur in some situations it never formally defines the term. The C Standard follows C90 in not explicitly defining this term. .