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 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<HTML>
<HEAD>
<TITLE>AARM95 - Suppressing Checks</TITLE>
<META NAME="Author" CONTENT="JTC1/SC22/WG9/ARG, by Randall Brukardt, ARG Editor">
<META NAME="GENERATOR" CONTENT="Arm_Form.Exe, Ada Reference Manual generator">
<STYLE type="text/css">
DIV.paranum {position: absolute; font-family: Arial, Helvetica, sans-serif; left: 0.5 em; top: auto}
TT {font-family: "Courier New", monospace}
DT {display: compact}
DIV.Normal {font-family: "Times New Roman", Times, serif; margin-bottom: 0.6em}
DIV.Wide {font-family: "Times New Roman", Times, serif; margin-top: 0.6em; margin-bottom: 0.6em}
DIV.Annotations {font-family: "Times New Roman", Times, serif; margin-left: 4.0em; margin-bottom: 0.6em}
DIV.WideAnnotations {font-family: "Times New Roman", Times, serif; margin-left: 4.0em; margin-top: 0.6em; margin-bottom: 0.6em}
DIV.Index {font-family: "Times New Roman", Times, serif}
DIV.SyntaxSummary {font-family: "Times New Roman", Times, serif; margin-left: 2.0em; margin-bottom: 0.4em}
DIV.Notes {font-family: "Times New Roman", Times, serif; margin-left: 2.0em; margin-bottom: 0.6em}
DIV.NotesHeader {font-family: "Times New Roman", Times, serif; margin-left: 2.0em}
DIV.SyntaxIndented {font-family: "Times New Roman", Times, serif; margin-left: 2.0em; margin-bottom: 0.4em}
DIV.Indented {font-family: "Times New Roman", Times, serif; margin-left: 6.0em; margin-bottom: 0.6em}
DIV.CodeIndented {font-family: "Times New Roman", Times, serif; margin-left: 4.0em; margin-bottom: 0.6em}
DIV.SmallIndented {font-family: "Times New Roman", Times, serif; margin-left: 10.0em; margin-bottom: 0.6em}
DIV.SmallCodeIndented {font-family: "Times New Roman", Times, serif; margin-left: 8.0em; margin-bottom: 0.6em}
DIV.Examples {font-family: "Courier New", monospace; margin-left: 2.0em; margin-bottom: 0.6em}
DIV.SmallExamples {font-family: "Courier New", monospace; font-size: 80%; margin-left: 7.5em; margin-bottom: 0.6em}
DIV.IndentedExamples {font-family: "Courier New", monospace; margin-left: 8.0em; margin-bottom: 0.6em}
DIV.SmallIndentedExamples {font-family: "Courier New", monospace; font-size: 80%; margin-left: 15.0em; margin-bottom: 0.6em}
UL.Bulleted {font-family: "Times New Roman", Times, serif; margin-left: 2.0em; margin-right: 2.0em; margin-top: 0em; margin-bottom: 0.5em}
UL.SmallBulleted {font-family: "Times New Roman", Times, serif; margin-left: 6.0em; margin-right: 6.0em; margin-top: 0em; margin-bottom: 0.5em}
UL.NestedBulleted {font-family: "Times New Roman", Times, serif; margin-left: 4.0em; margin-right: 4.0em; margin-top: 0em; margin-bottom: 0.5em}
UL.SmallNestedBulleted {font-family: "Times New Roman", Times, serif; margin-left: 8.0em; margin-right: 8.0em; margin-top: 0em; margin-bottom: 0.5em}
UL.IndentedBulleted {font-family: "Times New Roman", Times, serif; margin-left: 8.0em; margin-right: 8.0em; margin-top: 0em; margin-bottom: 0.5em}
UL.CodeIndentedBulleted {font-family: "Times New Roman", Times, serif; margin-left: 6.0em; margin-right: 6.0em; margin-top: 0em; margin-bottom: 0.5em}
UL.CodeIndentedNestedBulleted {font-family: "Times New Roman", Times, serif; margin-left: 8.0em; margin-right: 8.0em; margin-top: 0em; margin-bottom: 0.5em}
UL.SyntaxIndentedBulleted {font-family: "Times New Roman", Times, serif; margin-left: 4.0em; margin-right: 4.0em; margin-top: 0em; margin-bottom: 0.5em}
UL.NotesBulleted {font-family: "Times New Roman", Times, serif; margin-left: 4.0em; margin-right: 4.0em; margin-top: 0em; margin-bottom: 0.5em}
UL.NotesNestedBulleted {font-family: "Times New Roman", Times, serif; margin-left: 6.0em; margin-right: 6.0em; margin-top: 0em; margin-bottom: 0.5em}
DL.Hanging {font-family: "Times New Roman", Times, serif; margin-top: 0em; margin-bottom: 0.6em}
DD.Hanging {margin-left: 6.0em}
DL.IndentedHanging {font-family: "Times New Roman", Times, serif; margin-left: 4.0em; margin-top: 0em; margin-bottom: 0.6em}
DD.IndentedHanging {margin-left: 2.0em}
DL.HangingInBulleted {font-family: "Times New Roman", Times, serif; margin-left: 2.0em; margin-right: 2.0em; margin-top: 0em; margin-bottom: 0.5em}
DD.HangingInBulleted {margin-left: 4.0em}
DL.SmallHanging {font-family: "Times New Roman", Times, serif; margin-left: 4.0em; margin-top: 0em; margin-bottom: 0.6em}
DD.SmallHanging {margin-left: 7.5em}
DL.SmallIndentedHanging {font-family: "Times New Roman", Times, serif; margin-left: 8.0em; margin-top: 0em; margin-bottom: 0.6em}
DD.SmallIndentedHanging {margin-left: 2.0em}
DL.SmallHangingInBulleted {font-family: "Times New Roman", Times, serif; margin-left: 6.0em; margin-right: 6.0em; margin-top: 0em; margin-bottom: 0.5em}
DD.SmallHangingInBulleted {margin-left: 5.0em}
DL.Enumerated {font-family: "Times New Roman", Times, serif; margin-right: 0.0em; margin-top: 0em; margin-bottom: 0.5em}
DD.Enumerated {margin-left: 2.0em}
DL.SmallEnumerated {font-family: "Times New Roman", Times, serif; margin-left: 4.0em; margin-right: 4.0em; margin-top: 0em; margin-bottom: 0.5em}
DD.SmallEnumerated {margin-left: 2.5em}
DL.NestedEnumerated {font-family: "Times New Roman", Times, serif; margin-left: 2.0em; margin-right: 2.0em; margin-top: 0em; margin-bottom: 0.5em}
DL.SmallNestedEnumerated {font-family: "Times New Roman", Times, serif; margin-left: 6.0em; margin-right: 6.0em; margin-top: 0em; margin-bottom: 0.5em}
</STYLE>
</HEAD>
<BODY TEXT="#000000" BGCOLOR="#FFFFF0" LINK="#0000FF" VLINK="#800080" ALINK="#FF0000">
<P><A HREF="AA-TOC.html">Contents</A> <A HREF="AA-0-29.html">Index</A> <A HREF="AA-11-4-2.html">Previous</A> <A HREF="AA-11-6.html">Next</A></P>
<HR>
<H1> 11.5 Suppressing Checks</H1>
<DIV Class="Paranum"><FONT SIZE=-2>1</FONT></DIV>
<DIV Class="Normal"> A <FONT FACE="Arial, Helvetica">pragma</FONT>
Suppress gives permission to an implementation to omit certain language-defined
checks.</DIV>
<DIV Class="Paranum"><FONT SIZE=-2>2</FONT></DIV>
<DIV Class="Normal"> <A NAME="I4108"></A><A NAME="I4109"></A><A NAME="I4110"></A><A NAME="I4111"></A><A NAME="I4112"></A>A
<I>language-defined check</I> (or simply, a ``check'') is one of the
situations defined by this International Standard that requires a check
to be made at run time to determine whether some condition is true. <A NAME="I4113"></A>A
check <I>fails</I> when the condition being checked is false, causing
an exception to be raised. </DIV>
<DIV Class="Paranum"><FONT SIZE=-2>2.a</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1><B>Discussion: </B>All such checks
are defined under ``Dynamic Semantics'' in clauses and subclauses throughout
the standard. </FONT></DIV>
<H4 ALIGN=CENTER>Syntax</H4>
<DIV Class="Paranum"><FONT SIZE=-2>3</FONT></DIV>
<DIV Class="SyntaxIndented" Style="margin-bottom: 0.2em">The form of
a <FONT FACE="Arial, Helvetica">pragma</FONT> Suppress is as follows:
</DIV>
<DIV Class="Paranum"><FONT SIZE=-2>4</FONT></DIV>
<DIV Class="SyntaxIndented"> <B>pragma</B> <A NAME="I4114"></A>Suppress(<A NAME="I4115"></A><FONT FACE="Arial, Helvetica">identifier</FONT>
[, [On =>] <A NAME="I4116"></A><FONT FACE="Arial, Helvetica">name</FONT>]);</DIV>
<DIV Class="Paranum"><FONT SIZE=-2>5</FONT></DIV>
<DIV Class="SyntaxIndented"><A NAME="I4117"></A><A NAME="I4118"></A>A
<FONT FACE="Arial, Helvetica">pragma</FONT> Suppress is allowed only
immediately within a <FONT FACE="Arial, Helvetica">declarative_part</FONT>,
immediately within a <FONT FACE="Arial, Helvetica">package_specification</FONT>,
or as a configuration pragma. </DIV>
<H4 ALIGN=CENTER>Legality Rules</H4>
<DIV Class="Paranum"><FONT SIZE=-2>6</FONT></DIV>
<DIV Class="Normal"> The <FONT FACE="Arial, Helvetica">identifier</FONT>
shall be the name of a check. The <FONT FACE="Arial, Helvetica">name</FONT>
(if present) shall statically denote some entity.</DIV>
<DIV Class="Paranum"><FONT SIZE=-2>7</FONT></DIV>
<DIV Class="Normal"> For a <FONT FACE="Arial, Helvetica">pragma</FONT>
Suppress that is immediately within a <FONT FACE="Arial, Helvetica">package_specification</FONT>
and includes a <FONT FACE="Arial, Helvetica">name</FONT>, the <FONT FACE="Arial, Helvetica">name</FONT>
shall denote an entity (or several overloaded subprograms) declared immediately
within the <FONT FACE="Arial, Helvetica">package_specification</FONT>.
</DIV>
<H4 ALIGN=CENTER>Static Semantics</H4>
<DIV Class="Paranum"><FONT SIZE=-2>8</FONT></DIV>
<DIV Class="Normal"> A <FONT FACE="Arial, Helvetica">pragma</FONT>
Suppress gives permission to an implementation to omit the named check
from the place of the <FONT FACE="Arial, Helvetica">pragma</FONT> to
the end of the innermost enclosing declarative region, or, if the <FONT FACE="Arial, Helvetica">pragma</FONT>
is given in a <FONT FACE="Arial, Helvetica">package_specification</FONT>
and includes a <FONT FACE="Arial, Helvetica">name</FONT>, to the end
of the scope of the named entity. If the <FONT FACE="Arial, Helvetica">pragma</FONT>
includes a <FONT FACE="Arial, Helvetica">name</FONT>, the permission
applies only to checks performed on the named entity, or, for a subtype,
on objects and values of its type. Otherwise, the permission applies
to all entities. <A NAME="I4119"></A>If permission has been given to
suppress a given check, the check is said to be <I>suppressed</I>. </DIV>
<DIV Class="Paranum"><FONT SIZE=-2>8.a</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1><B>Ramification: </B>A check is
suppressed even if the implementation chooses not to actually generate
better code. <A NAME="I4120"></A>This allows the implementation to raise
Program_Error, for example, if the erroneousness is detected. </FONT></DIV>
<DIV Class="Paranum"><FONT SIZE=-2>9</FONT></DIV>
<DIV Class="Normal" Style="margin-bottom: 0.4em"> The following are
the language-defined checks: </DIV>
<DIV Class="Paranum"><FONT SIZE=-2>10</FONT></DIV>
<UL Class="Bulleted"><LI TYPE=DISC><A NAME="I4121"></A>[The following checks correspond to
situations in which the exception Constraint_Error is raised upon failure.]
</LI></UL>
<DIV Class="Paranum"><FONT SIZE=-2>11/1</FONT></DIV>
<DL Class="HangingInBulleted" Style="margin-bottom: 0.3em"><DT>{<I><A HREF="defect1.html#8652/0036">8652/0036</A></I>} <A NAME="I4122"></A>Access_Check
<DD Class="HangingInBulleted">
[When evaluating a dereference (explicit or implicit), check that the
value of the <FONT FACE="Arial, Helvetica">name</FONT> is not <B>null</B>.
When passing an actual parameter to a formal access parameter, check
that the value of the actual parameter is not <B>null</B>. <U>When evaluating
a <FONT FACE="Arial, Helvetica">discriminant_association</FONT> for an
access discriminant, check that the value of the discriminant is not
<B>null</B>.</U>]</DL>
<DIV Class="Paranum"><FONT SIZE=-2>12</FONT></DIV>
<DL Class="HangingInBulleted"><DT><A NAME="I4123"></A>Discriminant_Check <DD Class="HangingInBulleted">
[Check that the discriminants of a composite value have the values imposed
by a discriminant constraint. Also, when accessing a record component,
check that it exists for the current discriminant values.]</DL>
<DIV Class="Paranum"><FONT SIZE=-2>13</FONT></DIV>
<DL Class="HangingInBulleted"><DT><A NAME="I4124"></A>Division_Check <DD Class="HangingInBulleted">
[Check that the second operand is not zero for the operations /, rem
and mod.]</DL>
<DIV Class="Paranum"><FONT SIZE=-2>14</FONT></DIV>
<DL Class="HangingInBulleted"><DT><A NAME="I4125"></A>Index_Check <DD Class="HangingInBulleted">
[Check that the bounds of an array value are equal to the corresponding
bounds of an index constraint. Also, when accessing a component of an
array object, check for each dimension that the given index value belongs
to the range defined by the bounds of the array object. Also, when accessing
a slice of an array object, check that the given discrete range is compatible
with the range defined by the bounds of the array object.]</DL>
<DIV Class="Paranum"><FONT SIZE=-2>15</FONT></DIV>
<DL Class="HangingInBulleted"><DT><A NAME="I4126"></A>Length_Check <DD Class="HangingInBulleted">
[Check that two arrays have matching components, in the case of array
subtype conversions, and logical operators for arrays of boolean components.]</DL>
<DIV Class="Paranum"><FONT SIZE=-2>16</FONT></DIV>
<DL Class="HangingInBulleted"><DT><A NAME="I4127"></A>Overflow_Check <DD Class="HangingInBulleted">
[Check that a scalar value is within the base range of its type, in cases
where the implementation chooses to raise an exception instead of returning
the correct mathematical result.]</DL>
<DIV Class="Paranum"><FONT SIZE=-2>17</FONT></DIV>
<DL Class="HangingInBulleted"><DT><A NAME="I4128"></A>Range_Check <DD Class="HangingInBulleted">
[Check that a scalar value satisfies a range constraint. Also, for the
elaboration of a <FONT FACE="Arial, Helvetica">subtype_indication</FONT>,
check that the <FONT FACE="Arial, Helvetica">constraint</FONT> (if present)
is compatible with the subtype denoted by the <FONT FACE="Arial, Helvetica">subtype_mark</FONT>.
Also, for an <FONT FACE="Arial, Helvetica">aggregate</FONT>, check that
an index or discriminant value belongs to the corresponding subtype.
Also, check that when the result of an operation yields an array, the
value of each component belongs to the component subtype.]</DL>
<DIV Class="Paranum"><FONT SIZE=-2>18</FONT></DIV>
<DL Class="HangingInBulleted"><DT><A NAME="I4129"></A>Tag_Check <DD Class="HangingInBulleted">
[Check that operand tags in a dispatching call are all equal. Check for
the correct tag on tagged type conversions, for an <FONT FACE="Arial, Helvetica">assignment_statement</FONT>,
and when returning a tagged limited object from a function.] </DL>
<DIV Class="Paranum"><FONT SIZE=-2>19</FONT></DIV>
<UL Class="Bulleted"><LI TYPE=DISC><A NAME="I4130"></A>[The following checks correspond to
situations in which the exception Program_Error is raised upon failure.]
</LI></UL>
<DIV Class="Paranum"><FONT SIZE=-2>20</FONT></DIV>
<DL Class="HangingInBulleted" Style="margin-bottom: 0.3em"><DT><A NAME="I4131"></A>Elaboration_Check <DD Class="HangingInBulleted">
[When a subprogram or protected entry is called, a task activation is
accomplished, or a generic instantiation is elaborated, check that the
body of the corresponding unit has already been elaborated.]</DL>
<DIV Class="Paranum"><FONT SIZE=-2>21</FONT></DIV>
<DL Class="HangingInBulleted"><DT><A NAME="I4132"></A>Accessibility_Check <DD Class="HangingInBulleted">
[Check the accessibility level of an entity or view.]</DL>
<DIV Class="Paranum"><FONT SIZE=-2>22</FONT></DIV>
<UL Class="Bulleted" Style="margin-bottom: 0.3em"><LI TYPE=DISC>[The following check corresponds to situations in which
the exception Storage_Error is raised upon failure.] </LI></UL>
<DIV Class="Paranum"><FONT SIZE=-2>23</FONT></DIV>
<DL Class="HangingInBulleted"><DT><A NAME="I4133"></A><A NAME="I4134"></A>Storage_Check <DD Class="HangingInBulleted">
[Check that evaluation of an <FONT FACE="Arial, Helvetica">allocator</FONT>
does not require more space than is available for a storage pool. Check
that the space available for a task or subprogram has not been exceeded.]
</DL>
<DIV Class="Paranum"><FONT SIZE=-2>23.a</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1><B>Reason: </B>We considered splitting
this out into three categories: Pool_Check (for <FONT FACE="Arial, Helvetica">allocator</FONT>s),
Stack_Check (for stack usage), and Heap_Check (for implicit use of the
heap -- use of the heap other than through an <FONT FACE="Arial, Helvetica">allocator</FONT>).
Storage_Check would then represent the union of these three. However,
there seems to be no compelling reason to do this, given that it is not
feasible to split Storage_Error. </FONT></DIV>
<DIV Class="Paranum"><FONT SIZE=-2>24</FONT></DIV>
<UL Class="Bulleted" Style="margin-bottom: 0.3em"><LI TYPE=DISC>[The following check corresponds to all situations in which
any predefined exception is raised.] </LI></UL>
<DIV Class="Paranum"><FONT SIZE=-2>25</FONT></DIV>
<DL Class="HangingInBulleted"><DT><A NAME="I4135"></A>All_Checks <DD Class="HangingInBulleted">
Represents the union of all checks; [suppressing All_Checks suppresses
all checks.] </DL>
<DIV Class="Paranum"><FONT SIZE=-2>25.a</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1><B>Ramification: </B>All_Checks
includes both language-defined and implementation-defined checks. </FONT></DIV>
<H4 ALIGN=CENTER>Erroneous Execution</H4>
<DIV Class="Paranum"><FONT SIZE=-2>26</FONT></DIV>
<DIV Class="Normal"> <A NAME="I4136"></A>If a given check has been
suppressed, and the corresponding error situation occurs, the execution
of the program is erroneous. </DIV>
<H4 ALIGN=CENTER>Implementation Permissions</H4>
<DIV Class="Paranum"><FONT SIZE=-2>27</FONT></DIV>
<DIV Class="Normal"> An implementation is allowed to place restrictions
on Suppress <FONT FACE="Arial, Helvetica">pragma</FONT>s. An implementation
is allowed to add additional check names, with implementation-defined
semantics. <A NAME="I4137"></A>When Overflow_Check has been suppressed,
an implementation may also suppress an unspecified subset of the Range_Checks.
</DIV>
<DIV Class="Paranum"><FONT SIZE=-2>27.a</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1><B>Reason: </B>The permission
to restrict is given so the implementation can give an error message
when the requested suppression is nonsense, such as suppressing a Range_Check
on a task type. It would be verbose and pointless to list all the cases
of nonsensical language-defined checks in the standard, and since the
list of checks is open-ended, we can't list the restrictions for implementation-defined
checks anyway. </FONT></DIV>
<DIV Class="Paranum"><FONT SIZE=-2>27.b</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1><B>Implementation defined: </B>Implementation-defined
check names.</FONT></DIV>
<DIV Class="Paranum"><FONT SIZE=-2>27.c</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1><B>Discussion: </B>For Overflow_Check,
the intention is that the implementation will suppress any Range_Checks
that are implemented in the same manner as Overflow_Checks (unless they
are free). </FONT></DIV>
<H4 ALIGN=CENTER>Implementation Advice</H4>
<DIV Class="Paranum"><FONT SIZE=-2>28</FONT></DIV>
<DIV Class="Normal"> The implementation should minimize the code executed
for checks that have been suppressed. </DIV>
<DIV Class="Paranum"><FONT SIZE=-2>28.a</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1><B>Implementation Note: </B>However,
if a given check comes for free (for example, the hardware automatically
performs the check in parallel with doing useful work) or nearly free
(for example, the check is a tiny portion of an expensive run-time system
call), the implementation should not bother to suppress the check. Similarly,
if the implementation detects the failure at compile time and provides
a warning message, there is no need to actually suppress the check. </FONT></DIV>
<DIV Class="NotesHeader"><FONT SIZE=-1>NOTES</FONT></DIV>
<DIV Class="Paranum"><FONT SIZE=-2>29</FONT></DIV>
<DIV Class="Notes"><FONT SIZE=-1>2 <A NAME="I4138"></A><A NAME="I4139"></A>There
is no guarantee that a suppressed check is actually removed; hence a
<FONT FACE="Arial, Helvetica">pragma</FONT> Suppress should be used only
for efficiency reasons. </FONT></DIV>
<H4 ALIGN=CENTER>Examples</H4>
<DIV Class="Paranum"><FONT SIZE=-2>30</FONT></DIV>
<DIV Class="Normal" Style="margin-bottom: 0.4em"> <I>Examples of
suppressing checks:</I> </DIV>
<DIV Class="Paranum"><FONT SIZE=-2>31</FONT></DIV>
<DIV Class="Examples"><TT><B>pragma</B> Suppress(Range_Check);<BR>
<B>pragma</B> Suppress(Index_Check, On => Table);</TT></DIV>
<H4 ALIGN=CENTER>Extensions to Ada 83</H4>
<DIV Class="Paranum"><FONT SIZE=-2>31.a</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1><A NAME="I4140"></A>A <FONT FACE="Arial, Helvetica">pragma</FONT>
Suppress is allowed as a configuration pragma. A <FONT FACE="Arial, Helvetica">pragma</FONT>
Suppress without a <FONT FACE="Arial, Helvetica">name</FONT> is allowed
in a <FONT FACE="Arial, Helvetica">package_specification</FONT>.</FONT></DIV>
<DIV Class="Paranum"><FONT SIZE=-2>31.b</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1>Additional check names are added.
We allow implementations to define their own checks. </FONT></DIV>
<H4 ALIGN=CENTER>Wording Changes from Ada 83</H4>
<DIV Class="Paranum"><FONT SIZE=-2>31.c</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1>We define the checks in a distributed
manner. Therefore, the long list of what checks apply to what is merely
a NOTE.</FONT></DIV>
<DIV Class="Paranum"><FONT SIZE=-2>31.d</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1>We have removed the detailed rules
about what is allowed in a <FONT FACE="Arial, Helvetica">pragma</FONT>
Suppress, and allow implementations to invent their own. The RM83 rules
weren't quite right, and such a change is necessary anyway in the presence
of implementation-defined checks.</FONT></DIV>
<DIV Class="Paranum"><FONT SIZE=-2>31.e</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1>We make it clear that the difference
between a Range_Check and an Overflow_Check is fuzzy. This was true in
Ada 83, given RM83-11.6, but it was not clear. We considered removing
Overflow_Check from the language or making it obsolescent, just as we
did for Numeric_Error. However, we kept it for upward compatibility,
and because it may be useful on machines where range checking costs more
than overflow checking, but overflow checking still costs something.
Different compilers will suppress different checks when asked to suppress
Overflow_Check -- the non-uniformity in this case is not harmful, and
removing it would have a serious impact on optimizers.</FONT></DIV>
<DIV Class="Paranum"><FONT SIZE=-2>31.f</FONT></DIV>
<DIV Class="Annotations"><FONT SIZE=-1>Under Access_Check, dereferences
cover the cases of <FONT FACE="Arial, Helvetica">selected_component</FONT>,
<FONT FACE="Arial, Helvetica">indexed_component</FONT>, <FONT FACE="Arial, Helvetica">slice</FONT>,
and <FONT FACE="Arial, Helvetica">attribute</FONT> that are listed in
RM83, as well as the new <FONT FACE="Arial, Helvetica">explicit_dereference</FONT>,
which was included in <FONT FACE="Arial, Helvetica">selected_component</FONT>
in RM83. </FONT></DIV>
<HR>
<P><A HREF="AA-TOC.html">Contents</A> <A HREF="AA-0-29.html">Index</A> <A HREF="AA-11-4-2.html">Previous</A> <A HREF="AA-11-6.html">Next</A> <A HREF="AA-TTL.html">Legal</A></P>
</BODY>
</HTML>
|