osd@hou2d.UUCP (Orlando Sotomayor-Diaz) (05/11/86)
From: Orlando Sotomayor-Diaz (The Moderator) <cbosgd!std-c> mod.std.c Digest Sat, 10 May 86 Volume 16 : Issue 3 Today's Topics: Differences from April 1985 to February 1986 Draft Standard, Part 2 ---------------------------------------------------------------------- Date: Sun, 27 Apr 86 01:17:06 est From: <ihnp4!utcsri!lsuc!msb%utcsri> Subject: Differences from April 1985 to February 1986 Draft Standard, Part 2 To: cbosgd!std-c%utcsri # B.1.1.3 Diagnostics * A conforming implementation shall produce {a --> at least one} * diagnostic message for every {--> source file that contains a} violation of any syntax rule or constraint. # B.1.2.2 Hosted environment <--O The function called at program startup is called main, and can be <--O declared as <--O extern int main(int argc, char *argv[]); N--> The function called at program startup is called main. The im- N--> plementation declares no prototype for this function. It can be N--> defined with no parameters: N--> int main(void) { /*...*/ } N--> or two parameters (referred to here as argc and argv, though any N--> names may be used, as they are local to the function in which N--> they are declared): N--> int main(int argc, char *argv[]) { /*...*/ } * {--> If they are defined,} the parameters to main have the fol- lowing constraints: # B.1.2.3 Program execution <--O All output directed to interactive devices must occur before new <--O interactively generated input is accepted. N--> The input and output dynamics of interactive devices shall take N--> place as specified in #D.9. N--> ... The intent of the requirements of #D.9 is that unbuffered or N--> line-buffered output appear as soon as possible, to ensure that N--> prompting messages actually appear prior to a program waiting for N--> input. # B.1.2.3 Program execution N--> ... Alternatively, an operation involving only ints or floats N--> may be executed using double precision operations if neither N--> range nor precision is lost thereby. # B.1.2.3 Program execution * Forward references: ..., sequence points (#C.3, {--> #C.6}), ... # B.2.1 Character sets The following trigraph sequences ... shall be replaced by the specified characters ... N--> Any other trigraph sequence that begins with ?? is unchanged. The trigraph sequences enable the input of characters that are * not defined in the ISO {646 --> 646-1983} Invariant Code Set, which is a subset of the seven-bit ASCII code set. # B.2.2 Character display semantics * The "{printing --> active} position" is that location on a display device where the next character output by the fputc func- * tion would appear. The {effect --> intent} of writing a print- able character (as defined by the isprint function) to a display device is to display a graphic representation of that character * at the {current printing --> active} position and then advance * the {printing --> active} position to the next position on the * current line. {--> If the active position is at the final posi- tion of a line (if there is one), the behavior is unspecified.} Alphabetic escape sequences representing non-graphic characters * {--> in the execution character set are intended to} produce for- mat effecting actions on display devices as follows: * \a ("alert") Produces an {implementation-defined -->} audible or * visible representation of an alert character. {Any consequent alteration to the printing position is implementation-defined. --> The active position shall not be changed.} * ... \v ("vertical tab") Moves the {printing --> active} position * to the initial {printing --> active} position of the next * {implementation-defined -->} vertical tabulation position. {--> If the active position is at or past the last defined vertical tabulation position, the behavior is unspecified.} # B.2.3 Signals and interrupts Functions shall be implemented such that they may be interrupted at any time by a signal, and may be called by a signal handler * with no alteration {--> to control flow, to function return values, or} to objects with automatic storage duration belonging to earlier invocations. # B.2.3 Signals and interrupts N--> The functions in the standard library are not guaranteed to be N--> reentrant and may modify objects with static storage duration. # B.2.4.1 Translation limits * The implementation shall be able to {compile at least one --> * translate and execute a} program that {meets or exceeds all --> * contains at least one instance} of the following {translation -->} limits: * ... {6 --> 12} pointer, array, and function declarators modify- ing a basic type in a declaration * ... {1024 --> 127} identifiers with block scope in one block * 1024 macro identifiers {--> simultaneously defined} in one source file * 31 parameters in one function {--> definition and} call * 31 parameters in one macro {--> definition and invocation} N--> ... 509 characters in a string literal (after concatenation) N--> 32767 bytes in an object (in a hosted environment only) * {4 --> 8} nesting levels for #included files <--O maximum number of alphabetic cases in an external identifier (1) # B.2.4.2 Numerical limits A conforming implementation shall document all these items, which * are specified in the headers <limits.h> {--> and <float.h>}. * Sizes of integral types {--> <limits.h>} The values given below shall be replaced by implementation- * defined {values --> constant expressions} that shall be equal or greater in magnitude (absolute value). # B.2.4.2 Numerical limits * Characteristics of floating types {--> <float.h>} N--> The integer values given below shall be replaced by N--> implementation-defined constant expressions that shall be equal N--> or greater in magnitude (absolute value). Values that have N--> floating type need not be constant expressions. N--> The following apply to all three floating-point types and require N--> only one name. radix of exponent representation FLT_RADIX 2 * {DBL_RADIX 2 -->} * {LDBL_RADIX 2 -->} * addition rounds (1), chops (0), {--> or indeterminable during translation (-1)} FLT_ROUNDS 0 * {DBL_ROUNDS 0 -->} * {LDBL_ROUNDS 0 -->} N--> guard digits are used (1) or not used (0) for floating multipli- N--> cation N--> FLT_GUARD 0 N--> floating values must be normalized (1) or need not be (0) N--> FLT_NORMALIZE 0 <--O maximum power of 10 that can be represented ... <--O FLT_MAX_EXP +38 <--O DBL_MAX_EXP +38 <--O LDBL_MAX_EXP +38 <--O minimum power of 10 that can be represented ... <--O FLT_MIN_EXP -38 <--O DBL_MIN_EXP -38 <--O LDBL_MIN_EXP -38 N--> maximum representable finite floating-point number N--> FLT_MAX 1E+38 N--> DBL_MAX 1E+38 N--> LDBL_MAX 1E+38 N--> minimum representable positive floating-point number N--> FLT_MIN 1E-38 N--> DBL_MIN 1E-38 N--> LDBL_MIN 1E-38 N--> maximum integer such that FLT_RADIX raised to that power yields a N--> representable finite floating-point number N--> FLT_MAX_EXP N--> DBL_MAX_EXP N--> LDBL_MAX_EXP N--> minimum negative integer such that FLT_RADIX raised to that power N--> yields a representable positive floating-point number N--> FLT_MIN_EXP N--> DBL_MIN_EXP N--> LDBL_MIN_EXP N--> maximum integer such that 10 raised to that power yields a N--> representable finite floating-point number N--> FLT_MAX_10_EXP +38 N--> DBL_MAX_10_EXP +38 N--> LDBL_MAX_10_EXP +38 N--> minimum negative integer such that 10 raised to that power yields N--> a representable positive floating-point number N--> FLT_MIN_10_EXP -38 N--> DBL_MIN_10_EXP -38 N--> LDBL_MIN_10_EXP -38 number of decimal digits of precision FLT_DIG 6 DBL_DIG 6 LDBL_DIG 6 N--> number of base-FLT_RADIX digits in the floating-point mantissa N--> FLT_MANT_DIG N--> DBL_MANT_DIG N--> LDBL_MANT_DIG N--> number of base-FLT_RADIX digits in the floating-point exponent N--> (including bias or sign) N--> FLT_EXP_DIG N--> DBL_EXP_DIG N--> LDBL_EXP_DIG N--> minimum positive floating point number x such that 1.0 + x != 1.0 N--> FLT_POS_EPS 1E-5 N--> DBL_POS_EPS 1E-5 N--> LDBL_POS_EPS 1E-5 N--> minimum positive floating point number x such that 1.0 - x != 1.0 N--> FLT_NEG_EPS 1E-5 N--> DBL_NEG_EPS 1E-5 N--> LDBL_NEG_EPS 1E-5 N--> minimum integer such that FLT_RADIX raised to that power yields a N--> floating-point number x such that 1.0 + x != 1.0 N--> FLT_POS_EPS_EXP N--> DBL_POS_EPS_EXP N--> LDBL_POS_EPS_EXP N--> minimum integer such that FLT_RADIX raised to that power yields a N--> floating-point number x such that 1.0 - x != 1.0 N--> FLT_NEG_EPS_EXP N--> DBL_NEG_EPS_EXP N--> LDBL_NEG_EPS_EXP ------------------------------ End of mod.std.c Digest - Sat, 10 May 86 18:51:13 EDT ****************************** USENET -> posting only through cbosgd!std-c. ARPA -> ... through cbosgd!std-c@BERKELEY.ARPA (NOT to INFO-C) In all cases, you may also reply to the author(s) above.