Foreword
This document is the Annotated Ada Reference Manual.
The International Standard for the programming language Ada is ISO/IEC
8652:2023(E). The International Standard is derived from the Ada Reference
Manual, with various non-normative changes. In particular, the International
Standard numbers clauses differently, omits the annotations and paragraph
numbers, eliminates the Acknowledgements, and modifies various front
matter such as the Title page and the Foreword.
Discussion: New ISO requirements necessitated
changing the numbers of all of the numbered clauses and subclauses in
the International Standard. The Ada Reference Manual retains its traditional
numbering of clauses and subclauses as it is common for existing material
(both printed and electronic) to refer to subclauses just by number.
The Ada Working Group ISO/IEC JTC 1/SC 22/WG 9 is
tasked by ISO with the work item to interpret and maintain the International
Standard and to produce Technical Corrigenda, as appropriate. The technical
work on the International Standard is performed by the Ada Rapporteur
Group (ARG) of WG 9.
AXE Consultants produces the Ada Reference Manual
in consultation with the ARG, along with drafts of other documents as
needed. ISO/IEC documents often list the individual changes that need
to be made to the text of a Standard, rather than simply updating the
document. As such, an International Standard is often found in several
parts, while the Ada Reference Manual is always a single document.
In June 2016, WG 9 approved a tentative schedule
for the preparation of an Amendment or Revision to the International
Standard, with a delivery no earlier than 2018. In July 2019, WG 9 approved
an additional review and prototyping period for this revision, extending
the delivery to no earlier than late 2020. The draft standard was delivered
to WG 9 in July 2021, and the Standard was published as ISO/IEC 8652:2023
in May 2023.
Since the completion of Ada
2022, work has continued on Ada, both to correct errors and to add small
enhancements. Currently, there has been no determination of when or in
what form these changes will be issued. However, it is valuable to have
all of the corrections available in one place. Thus, we've created this
draft update, which for the purposes of this document, we'll Ada 202y.
{
AI12-0313-1}
{
AI12-0441-1}
This Ada Reference Manual replaces the edition of 2012. It modifies the
previous edition by making changes and additions that improve the capability
of the language and the reliability of programs written in the language.
{
AI12-0441-1}
Significant changes in this edition are as follows:
{
AI12-0313-1}
{
AI12-0441-1}
Improved support for parallel execution is provided via the introduction
of parallel loops, parallel blocks, parallel container iteration, and
parallel reduction.
{
AI12-0313-1}
{
AI12-0441-1}
More precise specification of subprogram interfaces is supported via
the new aspects Global, Global'Class, and Nonblocking. The Global aspects,
in particular, help to determine whether two constructs can safely execute
in parallel.
{
AI12-0313-1}
{
AI12-0441-1}
Pre and Post aspects can now be specified for access-to-subprogram types
and for generic formal subprograms; a postcondition for the default initialization
of a type can be specified using the new Default_Initial_Condition aspect.
{
AI12-0313-1}
{
AI12-0441-1}
The behavior of many predefined container operations is now more precisely
specified by using pre- and postcondition specifications instead of English
descriptions; a restricted (“stable”) view for most containers
is introduced to support more efficient iteration.
{
AI12-0313-1}
{
AI12-0441-1}
More flexible uses of static expressions are supported via the introduction
of static expression functions along with fewer restrictions on static
strings.
{
AI12-0313-1}
{
AI12-0441-1}
The Image attribute is supported for nonscalar types, and a user-specifiable
attribute Put_Image is provided, which determines the value of the Image
attribute for a user-defined type.
{
AI12-0313-1}
{
AI12-0441-1}
The use of numeric and string literals is generalized to allow their
use with other categories of types, via the new aspects Integer_Literal,
Real_Literal, and String_Literal.
{
AI12-0313-1}
{
AI12-0441-1}
Array and record aggregates are made more flexible: index parameters
are allowed in an array aggregate to define the components as a function
of their array index; discriminants can be defined more flexibly within
an aggregate for a variant record type.
{
AI12-0313-1}
{
AI12-0441-1}
New types of aggregates are provided: delta aggregates to allow the construction
of a new object by incremental updates to an existing object; container
aggregates to allow construction of an object of a container type by
directly specifying its elements.
{
AI12-0313-1}
{
AI12-0441-1}
A shorthand is provided, using the token '@', to refer to the target
of an assignment statement in the expression defining its new value.
{
AI12-0313-1}
{
AI12-0441-1}
Declare expressions are provided that permit the definition and use of
local constants or renamings, to allow a large expression to be simplified
by defining common parts as named entities.
{
AI12-0313-1}
{
AI12-0441-1}
Support for lightweight iteration is added via the introduction of procedural
iterators.
{
AI12-0313-1}
{
AI12-0441-1}
Support for the map-reduce programming strategy is added via the introduction
of reduction expressions.
{
AI12-0313-1}
{
AI12-0441-1}
For constructs that use iterators of any sort, a filter can be specified
that restricts the elements produced by the iteration to those that satisfy
the condition of the filter.
{
AI12-0313-1}
{
AI12-0441-1}
Predefined packages supporting arbitrary-precision integer and real arithmetic
are provided.
{
AI12-0313-1}
{
AI12-0441-1}
The Jorvik profile is introduced to support hard real-time applications
that want to go beyond the restrictions of the Ravenscar profile.
Ada 2005 and 2012 Editions sponsored in part by Ada-Europe