Ada Reference Manual - Ada Resource · PDF fileISO/IEC 8652:2007(E) Ed. 3 — Ada...

791
Ada Reference Manual, ISO/IEC 8652:2007(E) Ed. 3 Ada Reference Manual ISO/IEC 8652:1995(E) with Technical Corrigendum 1 and Amendment 1 Language and Standard Libraries Copyright © 1992, 1993, 1994, 1995 Intermetrics, Inc. Copyright © 2000 The MITRE Corporation, Inc. Copyright © 2004, 2005, 2006 AXE Consultants Copyright © 2004, 2005, 2006 Ada-Europe

Transcript of Ada Reference Manual - Ada Resource · PDF fileISO/IEC 8652:2007(E) Ed. 3 — Ada...

  • Ada Reference Manual, ISO/IEC 8652:2007(E) Ed. 3

    Ada Reference Manual

    ISO/IEC 8652:1995(E)

    with Technical Corrigendum 1

    and Amendment 1

    Language and Standard Libraries

    Copyright 1992, 1993, 1994, 1995 Intermetrics, Inc.

    Copyright 2000 The MITRE Corporation, Inc.

    Copyright 2004, 2005, 2006 AXE Consultants

    Copyright 2004, 2005, 2006 Ada-Europe

  • Ada Reference Manual - Language and Standard Libraries

    Copyright 1992, 1993, 1994, 1995, Intermetrics, Inc.

    This copyright is assigned to the U.S. Government. All rights reserved.

    This document may be copied, in whole or in part, in any form or by any means, as is or with alterations, provided that (1) alterations are clearly marked as alterations and (2) this copyright notice is included unmodified in any copy. Compiled copies of standard library units and examples need not contain this copyright notice so long as the notice is included in all copies of source code and documentation.

    Technical Corrigendum 1

    Copyright 2000, The MITRE Corporation. All Rights Reserved.

    This document may be copied, in whole or in part, in any form or by any means, as is, or with alterations, provided that (1) alterations are clearly marked as alterations and (2) this copyright notice is included unmodified in any copy. Any other use or distribution of this document is prohibited without the prior express permission of MITRE.

    You use this document on the condition that you indemnify and hold harmless MITRE, its Board of Trustees, officers, agents, and employees, from any and all liability or damages to yourself or your hardware or software, or third parties, including attorneys' fees, court costs, and other related costs and expenses, arising out of your use of this document irrespective of the cause of said liability.

    MITRE MAKES THIS DOCUMENT AVAILABLE ON AN "AS IS" BASIS AND MAKES NO WARRANTY, EXPRESS OR IMPLIED, AS TO THE ACCURACY, CAPABILITY, EFFICIENCY MERCHANTABILITY, OR FUNCTIONING OF THIS DOCUMENT. IN NO EVENT WILL MITRE BE LIABLE FOR ANY GENERAL, CONSEQUENTIAL, INDIRECT, INCIDENTAL, EXEMPLARY, OR SPECIAL DAMAGES, EVEN IF MITRE HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

    Amendment 1

    Copyright 2004, 2005, 2006, AXE Consultants. All Rights Reserved.

    This document may be copied, in whole or in part, in any form or by any means, as is, or with alterations, provided that (1) alterations are clearly marked as alterations and (2) this copyright notice is included unmodified in any copy. Any other use or distribution of this document is prohibited without the prior express permission of AXE.

    You use this document on the condition that you indemnify and hold harmless AXE, its board, officers, agents, and employees, from any and all liability or damages to yourself or your hardware or software, or

  • third parties, including attorneys' fees, court costs, and other related costs and expenses, arising out of your use of this document irrespective of the cause of said liability.

    AXE MAKES THIS DOCUMENT AVAILABLE ON AN "AS IS" BASIS AND MAKES NO WARRANTY, EXPRESS OR IMPLIED, AS TO THE ACCURACY, CAPABILITY, EFFICIENCY MERCHANTABILITY, OR FUNCTIONING OF THIS DOCUMENT. IN NO EVENT WILL AXE BE LIABLE FOR ANY GENERAL, CONSEQUENTIAL, INDIRECT, INCIDENTAL, EXEMPLARY, OR SPECIAL DAMAGES, EVEN IF AXE HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

    Consolidated Standard

    Copyright 2004, 2005, 2006, Ada-Europe.

    This document may be copied, in whole or in part, in any form or by any means, as is, or with alterations, provided that (1) alterations are clearly marked as alterations and (2) this copyright notice is included unmodified in any copy. Any other use or distribution of this document is prohibited without the prior express permission of Ada-Europe.

    You use this document on the condition that you indemnify and hold harmless Ada-Europe and its Board from any and all liability or damages to yourself or your hardware or software, or third parties, including attorneys' fees, court costs, and other related costs and expenses, arising out of your use of this document irrespective of the cause of said liability.

    ADA-EUROPE MAKES THIS DOCUMENT AVAILABLE ON AN "AS IS" BASIS AND MAKES NO WARRANTY, EXPRESS OR IMPLIED, AS TO THE ACCURACY, CAPABILITY, EFFICIENCY MERCHANTABILITY, OR FUNCTIONING OF THIS DOCUMENT. IN NO EVENT WILL ADA-EUROPE BE LIABLE FOR ANY GENERAL, CONSEQUENTIAL, INDIRECT, INCIDENTAL, EXEMPLARY, OR SPECIAL DAMAGES, EVEN IF ADA-EUROPE HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

  • ISO/IEC 8652:2007(E) Ed. 3 Ada Reference Manual

    i 10 November 2006 Table of Contents

    Table of Contents Table of Contents............................................................................................................i Foreword to this version of the Ada Reference Manual ...........................................xi Foreword.......................................................................................................................xii Introduction .................................................................................................................xiii Section 1: General..........................................................................................................1

    1.1 Scope .............................................................................................................................................1 1.1.1 Extent ......................................................................................................................................1 1.1.2 Structure .................................................................................................................................2 1.1.3 Conformity of an Implementation with the Standard.........................................................4 1.1.4 Method of Description and Syntax Notation.......................................................................5 1.1.5 Classification of Errors .........................................................................................................7

    1.2 Normative References ..................................................................................................................8 1.3 Definitions......................................................................................................................................8

    Section 2: Lexical Elements..........................................................................................9 2.1 Character Set.................................................................................................................................9 2.2 Lexical Elements, Separators, and Delimiters.........................................................................11 2.3 Identifiers .....................................................................................................................................12 2.4 Numeric Literals ..........................................................................................................................13

    2.4.1 Decimal Literals ...................................................................................................................13 2.4.2 Based Literals ......................................................................................................................14

    2.5 Character Literals .......................................................................................................................14 2.6 String Literals ..............................................................................................................................15 2.7 Comments....................................................................................................................................15 2.8 Pragmas .......................................................................................................................................16 2.9 Reserved Words..........................................................................................................................18

    Section 3: Declarations and Types ............................................................................19 3.1 Declarations.................................................................................................................................19 3.2 Types and Subtypes ...................................................................................................................20

    3.2.1 Type Declarations................................................................................................................22 3.2.2 Subtype Declarations..........................................................................................................23 3.2.3 Classification of Operations...............................................................................................24

    3.3 Objects and Named Numbers....................................................................................................25 3.3.1 Object Declarations .............................................................................................................26 3.3.2 Number Declarations...........................................................................................................28

    3.4 Derived Types and Classes .......................................................................................................29 3.4.1 Derivation Classes...............................................................................................................32

    3.5 Scalar Types ..................................................................................................................