!standard 1.1.4(9) 05-09-20 AI95-00433/05 !standard 2.3(8) !standard 2.5(5) !standard 2.6(9) !standard 2.8(29) !standard 3.2.2(15) !standard 3.3.1(27) !standard 3.3.1(29) !standard 3.3.1(31) !standard 3.3.1(33) !standard 3.3.2(10) !standard 3.6(30) !standard 3.7(37) !standard 3.9.4(1) !standard 3.10(22) !standard 3.10.1(19) !standard 3.10.1(20) !standard 3.10.1(21) !standard 4.3.3(43) !standard 4.4(15) !standard 6.5.1(1) !standard 6.7(1) !standard 8.3.1(1) !standard 9.1(24) !standard 9.11(3) !standard 9.11(6) !standard 9.11(7) !standard 9.11(8) !standard 9.11(9) !standard 9.11(10) !standard 10.1.2(8) !standard 11.3(6) !standard 11.4.3(2) !standard 11.4.3(6) !standard 12.5.5(5) !standard 12.6(18) !standard 12.7(11) !class amendment 05-05-18 !status Amendment 200Y 05-05-18 !status WG9 Approved 06-06-09 !status ARG Approved 12-0-0 05-06-19 !status work item 05-05-18 !status received 05-05-18 !priority High !difficulty Easy !subject Examples in the Standard !summary (See proposal.) !problem The examples in the RM must be updated to reflect the new language. !proposal Tuck did the examples in a stream-of-consciousness manner, and Pascal got the short stick to write an AI. !wording (See corrigendum.) !discussion The example of AI-407 depends on the example of 3.9.4 given here. !example An example for examples? Get real! !corrigendum 1.1.4(9) @drepl @fa ::= @b [@fa];@hr @fa ::= @b; | @b @fa; @dby @fa ::= @b [@fa];@hr @fa ::= @b; | @b @fa; !corrigendum 2.3(8) @drepl @xcode @dby @xcode@unicode<955>@unicode<940>@unicode<964>@unicode<969>@unicode<957> --@ft<@i< Plato>> @unicode<1063>@unicode<1072>@unicode<1081>@unicode<1082>@unicode<1086>@unicode<1074>@unicode<1089>@unicode<1082>@unicode<1080>@unicode<1081> --@ft<@i< Tchaikovsky>> @unicode<952> @unicode<966> --@ft<@i< Angles>>> !corrigendum 2.5(5) @drepl @xcode<'A' '*' ''' ' '> @dby @xcode<'A' '*' ''' ' ' 'L' '@unicode<1051>' '@unicode<923>' --@ft<@i< Various els.>> '@unicode<8734>' '@unicode<1488>' --@ft<@i< Big numbers - infinity and aleph.>>> !corrigendum 2.6(9) @drepl @xcode<"Message of the day:" "" --@ft<@i< a null string literal>> " " "A" """" --@ft<@i< three string literals of length 1>> "Characters such as $, %, and } are allowed in string literals"> @dby @xcode<"Message of the day:" "" --@ft<@i< a null string literal>> " " "A" """" --@ft<@i< three string literals of length 1>> "Characters such as $, %, and } are allowed in string literals" "Archimedes said ""@unicode<917>@unicode<973>@unicode<961>@unicode<951>@unicode<954>@unicode<945>""" "Volume of cylinder (@pir@unicode<178>h) = "> !corrigendum 2.8(29) @drepl @xcode<@b List(Off); --@ft<@i< turn off listing generation>> @b Optimize(Off); --@ft<@i< turn off optional optimizations>> @b Inline(Set_Mask); --@ft<@i< generate code for Set_Mask inline>> @b Suppress(Range_Check, On =@> Index); --@ft<@i< turn off range checking on Index>>> @dby @xcode<@b List(Off); --@ft<@i< turn off listing generation>> @b Optimize(Off); --@ft<@i< turn off optional optimizations>> @b Inline(Set_Mask); --@ft<@i< generate code for Set_Mask inline>> @b Import(C, Put_Char, External_Name =@> "putchar"); --@ft<@i< import C putchar function>>> !corrigendum 3.2.2(15) @drepl @xcode<@b Rainbow @b Color @b Red .. Blue; --@ft<@i< see 3.2.1>> @b Red_Blue @b Rainbow; @b Int @b Integer; @b Small_Int @b Integer @b -10 .. 10; @b Up_To_K @b Column @b 1 .. K; --@ft<@i< see 3.2.1>> @b Square @b Matrix(1 .. 10, 1 .. 10); --@ft<@i< see 3.6>> @b Male @b Person(Sex =@> M); --@ft<@i< see 3.10.1>>> @dby @xcode<@b Rainbow @b Color @b Red .. Blue; --@ft<@i< see 3.2.1>> @b Red_Blue @b Rainbow; @b Int @b Integer; @b Small_Int @b Integer @b -10 .. 10; @b Up_To_K @b Column @b 1 .. K; --@ft<@i< see 3.2.1>> @b Square @b Matrix(1 .. 10, 1 .. 10); --@ft<@i< see 3.6>> @b Male @b Person(Sex =@> M); --@ft<@i< see 3.10.1>> @b Binop_Ref @b Binop_Ptr; --@ft<@i< see 3.10>>> !corrigendum 3.3.1(27) @drepl @xcode Person(Sex =@> M); --@ft<@i< see 3.10.1>>> @dby @xcode Person_Name := @b Person(Sex =@> M); --@ft<@i< see 3.10.1>>> !corrigendum 3.3.1(29) @drepl @xcode Person(Sex =@> M); Paul : Person_Name := @b Person(Sex =@> M);> @dby @xcode Person_Name := @b Person(Sex =@> M); Paul : @b Person_Name := @b Person(Sex =@> M);> !corrigendum 3.3.1(31) @drepl @xcode 0 .. 10_000 := 0; Sorted : Boolean := False; Color_Table : @b(1 .. Max) @b Color; Option : Bit_Vector(1 .. 10) := (@b =@> True); Hello : @b String := "Hi, world.";> @dby @xcode 0 .. 10_000 := 0; Sorted : Boolean := False; Color_Table : @b(1 .. Max) @b Color; Option : Bit_Vector(1 .. 10) := (@b =@> True); Hello : @b String := "Hi, world."; @unicode<952>, @unicode<966> : Float @b -@pi .. +@pi;> !corrigendum 3.3.1(33) @drepl @xcode Integer := 10_000; Low_Limit : @b Integer := Limit/10; Tolerance : @b Real := Dispersion(1.15);> @dby @xcode Integer := 10_000; Low_Limit : @b Integer := Limit/10; Tolerance : @b Real := Dispersion(1.15); Hello_Msg : @b String := Hello'Access; --@ft<@i< see 3.10.2>>> !corrigendum 3.3.2(10) !comment This is just a correction to an existing example. @drepl @xcode := 500; --@ft<@i< an integer number>> Max_Line_Size : @b := Max/6 --@ft<@i< the integer 83>> Power_16 : @b := 2**16; --@ft<@i< the integer 65_536>> One, Un, Eins : @b := 1; --@ft<@i< three different names for 1>>> @dby @xcode := 500; --@ft<@i< an integer number>> Max_Line_Size : @b := Max/6; --@ft<@i< the integer 83>> Power_16 : @b := 2**16; --@ft<@i< the integer 65_536>> One, Un, Eins : @b := 1; --@ft<@i< three different names for 1>>> !corrigendum 3.6(30) @drepl @xcode(1 .. 80, 1 .. 100) @b Boolean; Mix : @b(Color @b Red .. Green) @b Boolean; Page : @b(Positive @b <@>) @b Line := --@ft<@i< an array of arrays>> (1 | 50 =@> Line'(1 | Line'Last =@> '+', @b =@> '-'), --@ft<@i< see 4.3.3>> 2 .. 49 =@> Line'(1 | Line'Last =@> '|', @b =@> ' ')); --@ft<@i< Page is constrained by its initial value to (1..50)>>> @dby @xcode(1 .. 80, 1 .. 100) @b Boolean; Mix : @b(Color @b Red .. Green) @b Boolean; Msg_Table : @b(Error_Code) @b String := (Too_Big =@> @b String'("Result too big"), Too_Small =@> ...); Page : @b(Positive @b <@>) @b Line := --@ft<@i< an array of arrays>> (1 | 50 =@> Line'(1 | Line'Last =@> '+', @b =@> '-'), --@ft<@i< see 4.3.3>> 2 .. 49 =@> Line'(1 | Line'Last =@> '|', @b =@> ' ')); --@ft<@i< Page is constrained by its initial value to (1..50)>>> !corrigendum 3.7(37) @drepl @xcode<@b Item(Number : Positive) @b Content : Integer; --@ft<@i< no component depends on the discriminant>> @b;> @dby @xcode<@b Worker(Prio : System.Priority; Buf : @b Buffer) @b --@ft<@i< discriminants used to parameterize the task type (see 9.1)>> @b Priority(Prio); --@ft<@i< see D.1>> @b Fill; @b Drain; @b Worker;> !corrigendum 3.9.4(1) !comment This is not the full section, see the conflict files for that. @dinsa Nonlimited interface types have predefined nonabstract equality operators. These may be overridden with user-defined abstract equality operators. Such operators will then require an explicit overriding for any nonabstract descendant of the interface. @dinss @i<@s8> @i @xcode<@b Queue @b; @b Append(Q : @b Queue; Person : @b Person_Name) @b; @b Remove_First(Q : @b Queue; Person : @b Person_Name) @b; @b Cur_Count(Q : @b Queue) @b Natural @b; @b Max_Count(Q : @b Queue) @b Natural @b; -- @ft<@i> Queue_Error : @b; --@ft<@i< Append raises Queue_Error if Count(Q) = Max_Count(Q)>> --@ft<@i< Remove_First raises Queue_Error if Count(Q) = 0>> @b Synchronized_Queue @b Queue; --@ft<@i< see 9.11>> @b Append_Wait(Q : @b Synchronized_Queue; Person : @b Person_Name) @b; @b Remove_First_Wait(Q : @b Synchronized_Queue; Person : @b Person_Name) @b; ... @b Transfer(From : @b Queue'Class; To : @b Queue'Class; Number : @b Natural := 1) @b Person : Person_Name; @b @b I @b 1..Number @b Remove_First(From, Person); Append(To, Person); @b; @b Transfer;> This defines a Queue interface defining a queue of people. (A similar design could be created to define any kind of queue simply by replacing Person_Name by an appropriate type.) The Queue interface has four dispatching operations, Append, Remove_First, Cur_Count, and Max_Count. The body of a class-wide operation, Transfer is also shown. Every non-abstract extension of Queue must provide implementations for at least its four dispatching operations, as they are abstract. Any object of a type derived from Queue may be passed to Transfer as either the From or the To operand. The two operands need not be of the same type in any given call. The Synchronized_Queue interface inherits the four dispatching operations from Queue and adds two additional dispatching operations, which wait if necessary rather than raising the Queue_Error exception. This synchronized interface may only be implemented by a task or protected type, and as such ensures safe concurrent access. @i @xcode<@b Fast_Food_Queue @b Queue @b ...; @b Append(Q : @b Fast_Food_Queue; Person : @b Person_Name); @b Remove_First(Q : @b Fast_Food_Queue; Person : @b Person_Name); @b Cur_Count(Q : @b Fast_Food_Queue) @b Natural; @b Max_Count(Q : @b Fast_Food_Queue) @b Natural; ... Cashier, Counter : Fast_Food_Queue; ... -- @ft<@i> Append (Cashier, George); -- @ft<@i> Transfer (Cashier, Counter); ...> An interface such as Queue can be used directly as the parent of a new type (as shown here), or can be used as a progenitor when a type is derived. In either case, the primitive operations of the interface are inherited. For Queue, the implementation of the four inherited routines must be provided. Inside the call of Transfer, calls will dispatch to the implementations of Append and Remove_First for type Fast_Food_Queue. @i @xcode<@b Serial_Device @b; --@ft<@i< see 9.1>> @b Read (Dev : @b Serial_Device; C : @b Character) @b; @b Write(Dev : @b Serial_Device; C : @b Character) @b;> The Serial_Device interface has two dispatching operations which are intended to be implemented by task entries (see 9.1). !corrigendum 3.10(22) @drepl @xcode<@b Peripheral_Ref @b Peripheral; --@ft<@i< see 3.8.1>> @b Binop_Ptr @b Binary_Operation'Class; --@ft<@i< general access-to-class-wide, see 3.9.1>>> @dby @xcode<@b Peripheral_Ref @b Peripheral; --@ft<@i< see 3.8.1>> @b Binop_Ptr @b Binary_Operation'Class; --@ft<@i< general access-to-class-wide, see 3.9.1>>> !corrigendum 3.10.1(19) @drepl @xcode<@b Person(<@>); --@ft<@i< incomplete type declaration>> @b Car; --@ft<@i< incomplete type declaration>>> @dby @xcode<@b Person(<@>); --@ft<@i< incomplete type declaration>> @b Car @b; --@ft<@i< incomplete type declaration>>> !corrigendum 3.10.1(20) @drepl @xcode<@b Person_Name @b Person; @b Car_Name @b Car;> @dby @xcode<@b Person_Name @b Person; @b Car_Name @b Car'Class;> !corrigendum 3.10.1(21) @drepl @xcode<@b Car @b @b Number : Integer; Owner : Person_Name; @b;> @dby @xcode<@b Car @b @b Number : Integer; Owner : Person_Name; @b;> !corrigendum 4.3.3(43) @dinsa @xcode True); --@ft<@i< see 3.6>> E : Bit_Vector(M .. N) := (@b =@> True); F : String(1 .. 1) := (1 =@> 'F'); --@ft<@i< a one component aggregate: same as "F">>> @dinss @i @xcode 50, Pos =@> 1, Value =@> String'('x', @b =@> <@>)) --@ft<@i< see 3.7>>> !corrigendum 4.4(15) @drepl @xcode> @b Destroyed --@ft<@i< factor>> 2*Line_Count --@ft<@i< term>> -4.0 --@ft<@i< simple expression>> -4.0 + A --@ft<@i< simple expression>> B**2 - 4.0*A*C --@ft<@i< simple expression>> Password(1 .. 3) = "Bwv" --@ft<@i< relation>> Count @b Small_Int --@ft<@i< relation>> Count @b Small_Int --@ft<@i< relation>> Index = 0 @b Item_Hit --@ft<@i< expression>> (Cold @b Sunny) @b Warm --@ft<@i< expression (parentheses are required)>> A**(B**C) --@ft<@i< expression (parentheses are required)>>> @dby @xcode> @b Destroyed --@ft<@i< factor>> 2*Line_Count --@ft<@i< term>> -4.0 --@ft<@i< simple expression>> -4.0 + A --@ft<@i< simple expression>> B**2 - 4.0*A*C --@ft<@i< simple expression>> R*Sin(@unicode<952>)*Cos(@unicode<966>) --@ft<@i< simple expression>> Password(1 .. 3) = "Bwv" --@ft<@i< relation>> Count @b Small_Int --@ft<@i< relation>> Count @b Small_Int --@ft<@i< relation>> Index = 0 @b Item_Hit --@ft<@i< expression>> (Cold @b Sunny) @b Warm --@ft<@i< expression (parentheses are required)>> A**(B**C) --@ft<@i< expression (parentheses are required)>>> !corrigendum 6.5.1(1) !Comment This is a new clause, so this a dummy and the real thing is in the !comment conflicts. @dinsa If the body of a non-returning procedure completes normally, Program_Error is raised at the point of the call. @dinss @i<@s8> @xcode<@b Fail(Msg : String); --@ft<@i< raises Fatal_Error exception>> @b No_Return(Fail); --@ft<@i< Inform compiler and reader that procedure never returns normally>>> !corrigendum 6.7(1) !Comment This is a new clause, so this a dummy and the real thing is in the !comment conflicts. @dinsa The execution of a null procedure is invoked by a subprogram call. For the execution of a subprogram call on a null procedure, the execution of the @fa has no effect. @dinst @i<@s8> @xcode<@b Simplify(Expr : @b Expression) @b; --@ft<@i< see 3.9>> --@ft<@i< By default, Simplify does nothing, but it may be overridden in extensions of Expression>>> !corrigendum 8.3.1(1) !Comment This is a new clause, so this a dummy and the real thing is in the !comment conflicts. @dinsa Indicator! @dinst @i<@s8> The use of @fas allows the detection of errors at compile-time that otherwise might not be detected at all. For instance, we might declare a security queue derived from the Queue interface of 3.9.4 as: @xcode<@b Security_Queue @b Queue @b ...;> @xcode<@b @b Append(Q : @b Security_Queue; Person : @b Person_Name);> @xcode<@b @b Remove_First(Q : @b Security_Queue; Person : @b Person_Name);> @xcode<@b @b Cur_Count(Q : @b Security_Queue) @b Natural;> @xcode<@b @b Max_Count(Q : @b Security_Queue) @b Natural;> @xcode<@b @b Arrest(Q : @b Security_Queue; Person : @b Person_Name);> The first four subprogram declarations guarantee that these subprograms will override the four subprograms inherited from the Queue interface. A misspelling in one of these subprograms will be detected by the implementation. Conversely, the declaration of Arrest guarantees that this is a new operation. !corrigendum 9.1(24) @drepl @xcode<@b Keyboard_Driver(ID : Keyboard_ID := New_ID) @b @b Read (C : @b Character); @b Write(C : @b Character); @b Keyboard_Driver;> @dby @xcode<@b Keyboard_Driver(ID : Keyboard_ID := New_ID) @b @b Serial_Device @b --@ft<@i< see 3.9.4>> @b Read (C : @b Character); @b Write(C : @b Character); @b Keyboard_Driver;> !corrigendum 9.11(3) @drepl @xcode<@b Producer @b Char : Character; @b @b ... --@ft<@i< produce the next character Char>> Buffer.Write(Char); @b Char = ASCII.EOT; @b; @b Producer;> @dby @xcode<@b Producer @b Person : Person_Name; --@ft<@i< see 3.10.1>> @b @b ... --@ft<@i< simulate arrival of the next customer>> Buffer.Append_Wait(Person); @b Person = @b; @b; @b Producer;> !corrigendum 9.11(6) @drepl @xcode<@b Consumer @b Char : Character; @b Buffer.Read(Char); @b Char = ASCII.EOT; ... --@ft<@i< consume the character Char>> @b Consumer;> @dby @xcode<@b Consumer @b Person : Person_Name; @b Buffer.Remove_First_Wait(Person); @b Person = @b; ... --@ft<@i< simulate serving a customer>> @b; @b Consumer;> !corrigendum 9.11(7) @drepl The buffer object contains an internal pool of characters managed in a round-robin fashion. The pool has two indices, an In_Index denoting the space for the next input character and an Out_Index denoting the space for the next output character. @dby The buffer object contains an internal array of person names managed in a round-robin fashion. The array has two indices, an In_Index denoting the index for the next input person name and an Out_Index denoting the index for the next output person name. The Buffer is defined as an extension of the Synchronized_Queue interface (see 3.9.4), and as such promises to implement the abstraction defined by that interface. By doing so, the Buffer can be passed to the Transfer class-wide operation defined for objects of a type covered by Queue'Class. !corrigendum 9.11(8) @drepl @xcode<@b Buffer @b Read (C : @b Character); @b Write(C : @b Character); @b Pool : String(1 .. 100); Count : Natural := 0; In_Index, Out_Index : Positive := 1; @b Buffer;> @dby @xcode<@b Buffer @b Synchronized_Queue @b --@ft<@i< see 3.9.4>> @b Append_Wait(Person : @b Person_Name); @b Remove_First_Wait(Person : @b Person_Name); @b Cur_Count @b Natural; @b Max_Count @b Natural; @b Append(Person : @b Person_Name); @b Remove_First(Person : @b Person_Name); @b Pool : Person_Name_Array(1 .. 100); Count : Natural := 0; In_Index, Out_Index : Positive := 1; @b Buffer;> !corrigendum 9.11(9) @drepl @xcode<@b Buffer @b Write(C : @b Character) @b Count < Pool'Length @b Pool(In_Index) := C; In_Index := (In_Index @b Pool'Length) + 1; Count := Count + 1; @b Write;> @dby @xcode<@b Buffer @b @b Append_Wait(Person : @b Person_Name) @b Count < Pool'Length @b @b Append(Person); @b Append_Wait; @b Append(Person : @b Person_Name) @b @b @b Count = Pool'Length @b @b Queue_Error @b "Buffer Full"; --@ft<@i< see 11.3>> @b; Pool(In_Index) := Person; In_Index := (In_Index @b Pool'Length) + 1; Count := Count + 1; @b Append;> !corrigendum 9.11(10) @drepl @xcode< @b Read(C : @b Character) @b Count @> 0 @b @b C := Pool(Out_Index); Out_Index := (Out_Index @b Pool'Length) + 1; Count := Count - 1; @b Read; @b Buffer;> @dby @xcode< @b Remove_First_Wait(Person : @b Person_Name) @b Count @> 0 @b @b Remove_First(Person); @b Remove_First_Wait; @b Remove_First(Person : @b Person_Name) @b @b @b Count = 0 @b @b Queue_Error @b "Buffer Empty"; --@ft<@i< see 11.3>> @b; Person := Pool(Out_Index); Out_Index := (Out_Index @b Pool'Length) + 1; Count := Count - 1; @b Remove_First; @b Cur_Count @b Natural @b @b @b Buffer.Count; @b Cur_Count; @b Max_Count @b Natural @b @b @b Pool'Length; @b Max_Count; @b Buffer;> !corrigendum 10.1.2(8) !comment There is a lot of text inserted here, so this a dummy and the real !comment thing is in the conflicts. @dinsa @xbullet which names an entity declared within the declarative region of the @fa.> @dinss @i<@s8> @xcode<@b Office @b @b Office;> @xcode<@b Ada.Strings.Unbounded; @b Office.Locations @b @b Location @b Ada.Strings.Unbounded.Unbounded_String; @b Office.Locations;> @xcode<@b Office.Departments; --@ft<@i< types are incomplete>> @b Office.Locations; --@ft<@i< only visible in private part>> @b Office.Employees @b @b Employee @b; @b Dept_Of(Emp : Employee) @b Departments.Department; @b Assign_Dept(Emp : @b Employee; Dept : @b Departments.Department); ... @b @b Employee @b @b Dept : @b Departments.Department; Loc : Locations.Location; ... @b; @b Office.Employees; @b Office.Employees; @b Office.Departments @b @b Department @b; @b Manager_Of(Dept : Department) @b Employees.Employee; @b Assign_Manager(Dept : @b Department; Mgr : @b Employees.Employee); ... @b Office.Departments;> The @fa may be used to support mutually dependent abstractions that are split across multiple packages. In this case, an employee is assigned to a department, and a department has a manager who is an employee. If a @fa with the reserved word @b appears on one library unit and mentions a second library unit, it provides visibility to the second library unit, but restricts that visibility to the private part and body of the first unit. The compiler checks that no use is made of the second unit in the visible part of the first unit. !corrigendum 11.3(6) @drepl @xcode<@b Ada.IO_Exceptions.Name_Error; --@ft<@i< see A.13>>> @dby @xcode<@b Ada.IO_Exceptions.Name_Error; --@ft<@i< see A.13>> @b Queue_Error @b "Buffer Full"; --@ft<@i< see 9.11>>> !corrigendum 11.4.3(2) @drepl @xcode<@b Ada.Exceptions; @b Ada; @b File_System @b @b File_Handle @b;> @dby @xcode<@b File_System @b @b File_Handle @b;> !corrigendum 11.4.3(6) @drepl @xcode<@b File_System @b @b Open(F : @b File_Handle; Name : String) @b @b @b File_Exists(Name) @b ... @b Exceptions.Raise_Exception(File_Not_Found'Identity, "File not found: " & Name & "."); @b; @b Open;> @dby @xcode<@b File_System @b @b Open(F : @b File_Handle; Name : String) @b @b @b File_Exists(Name) @b ... @b @b File_Not_Found @b "File not found: " & Name & "."; @b; @b Open;> !corrigendum 12.5.5(1) !Comment This is a new clause, so this a dummy and the real thing is in the !comment conflicts. @dinsa The actual type shall be a limited, task, protected, or synchronized interface if and only if the formal type is also, respectively, a limited, task, protected, or synchronized interface. @dinss @i<@s8> @xcode<@b Root_Work_Item @b;> @xcode<@b @b Managed_Task @b; @b Work_Item(<@>) @b Root_Work_Item @b; @b Server_Manager @b @b Server @b Managed_Task @b @b Start(Data : @b Work_Item); @b Server; @b Server_Manager;> This generic allows an application to establish a standard interface that all tasks need to implement so they can be managed appropriately by an application-specific scheduler. !corrigendum 12.6(18) @drepl @xcode<@b @b "+"(X, Y : Item) @b Item @b <@>; @b @b Image(X : Enum) @b String @b Enum'Image; @b @b Update @b Default_Update;> @dby @xcode<@b "+"(X, Y : Item) @b Item @b <@>; @b @b Image(X : Enum) @b String @b Enum'Image; @b @b Update @b Default_Update; @b @b Pre_Action(X : @b Item) @b; --@ft<@i< defaults to no action>> @b @b Write(S : @b Root_Stream_Type'Class; Desc : Descriptor) @b Descriptor'Write; --@ft<@i< see 13.13.2>> --@ft<@i< Dispatching operation on Descriptor with default>>> !corrigendum 12.7(11) @dinsa For the purposes of matching, if the actual instance @i is itself a formal package, then the actual parameters of @i are those specified explicitly or implicitly in the @fa for @i, plus, for those not specified, the copies of the formal parameters of the template included in the visible part of @i. @dinss @i<@s8> @i @xcode<@b Ada.Containers.Ordered_Maps; --@ft<@i< see A.18.6>> @b @b Mapping_1 @b Ada.Containers.Ordered_Maps(<@>); @b Mapping_2 @b Ada.Containers.Ordered_Maps (Key_Type =@> Mapping_1.Element_Type, @b =@> <@>); @b Ordered_Join @b --@ft<@i< Provide a "join" between two mappings>> @b Key_Type @b Mapping_1.Key_Type; @b Element_Type @b Mapping_2.Element_Type; @b Lookup(Key : Key_Type) @b Element_Type; ... @b Ordered_Join;> @i @xcode<@b Ada.Containers.Ordered_Maps; @b Symbol_Package @b @b String_Id @b ... @b Symbol_Info @b ... @b String_Table @b Ada.Containers.Ordered_Maps (Key_Type =@> String, Element_Type =@> String_Id); @b Symbol_Table @b Ada.Containers.Ordered_Maps (Key_Type =@> String_Id, Element_Type =@> Symbol_Info); @b String_Info @b Ordered_Join(Mapping_1 =@> String_Table, Mapping_2 =@> Symbol_Table); Apple_Info : @b Symbol_Info := String_Info.Lookup("Apple");> @b Symbol_Package; !ACATS test This one is going to be hard to test! !appendix From: Georg Bauhaus Sent: Wednesday, August 10, 2005 4:05 PM !topic mistyped type in example? !reference Amendmend D12 3.9.4 !discussion Clause 3.9.4 in Amendment-D12.html presents an example of a descendant interface, viz. Synchronized_Queue. Two new primitive operations are to be added. However, the two procedures following Synchronized_Queue only have a Queue parameter, not a Synchronized_Queue parameter. Is this correct? **************************************************************** From: Randy Brukardt Sent: Wednesday, August 10, 2005 4:10 PM That was noticed during the review of the examples at the York ARG meeting. (The examples were newly added in April.) There were several dozen changes to the new examples (all marked as part of AI-433). ****************************************************************