!standard A.5.3 (50) 99-07-08 AI95-00055/02 !class confirmation 95-06-25 !status WG9 Approved 97-11-14 !status ARG approved (6-1-0) subject to editorial review 97-04-11 !status work item 95-06-25 !status received 95-06-25 !priority Low !difficulty Easy !subject Overflow for Adjacent, Machine, and Model attributes !summary The Adjacent, Machine, and Model attributes raise Constraint_Error under the conditions specified in the RM, even if the Machine_Overflows attribute is False. !question The Adjacent, Machine, and Model attributes raise Constraint_Error under certain overflow conditions (see A.5.3(50,62), G.2.2(07)). The description does not mention Machine_Overflows. Thus, Constraint_Error is raised even if Machine_Overflows is False. Is this the intent? (Yes.) !response The intent is that Machine_Overflows does not affect the raising of Constraint_Error by the Adjacent, Machine, and Model attributes. The RM wording is correct as is. As shown in the AARM, these checks are Range_Checks, not Overflow_Checks. Furthermore, the efficiency concerns that lead to allowing Machine_Overflows to be False do not apply here. These attributes typically take many machine instructions to execute, as compared to, for example, a multiply, where an overflow check would be a substantial relative overhead on some machines. !ACATS test It is not possible to test if the Adjacent, Machine, and Model attributes raise Constraint_Error. Constructing values that would leave the base range of a type (and trigger the constraint error) would require more knowledge about the numeric models of an implementation than is available to an ACATS test. !appendix !section A.5.3(50) !subject Mistake in description for floating point attribute S'Adjacent !reference RM95-A.5.3(50) !from Samuel Figueroa (figueroa@cs.nyu.edu) 95-06-16 !reference as: 95-5159.a Samuel Figueroa 95-6-16>> !discussion If the result would be outside the base range of S {and S'Machine_Overflows is True}, Constraint_Error is raised. **************************************************************** !section A.5.3(62) !subject Mistake in description for floating point attribute S'Machine !reference RM95-A.5.3(62) !from Samuel Figueroa (figueroa@cs.nyu.edu) 95-06-16 !reference as: 95-5159.b Samuel Figueroa 95-6-16>> !discussion Constraint_Error is raised if {S'Machine_Overflows is True and} rounding or truncating X to the precision of the machine numbers results in a value outside the base range of S. **************************************************************** !section G.2.2(07) !subject Mistake in description for floating point attribute S'Model !reference RM95-G.2.2(7) !from Samuel Figueroa (figueroa@cs.nyu.edu) 95-06-16 !reference as: 95-5159.c Samuel Figueroa 95-6-16>> !discussion Constraint_Error is raised if {S'Machine_Overflows is True and} the resulting model number is outside the safe range of S. ****************************************************************