]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
[Ada] Use bracket aggregates in Ada2022
authorMarc Poulhiès <poulhies@adacore.com>
Fri, 5 Nov 2021 09:24:27 +0000 (10:24 +0100)
committerPierre-Marie de Rodat <derodat@adacore.com>
Thu, 2 Dec 2021 16:26:27 +0000 (16:26 +0000)
gcc/ada/

* exp_imgv.adb (Append_Table_To): Add new parameter to
Make_Aggregate call.
* gen_il-fields.ads (Opt_Field_Enum):
Add Is_Parenthesis_Aggregate and Is_Enum_Array_Aggregate.
* gen_il-gen-gen_nodes.adb (Union): Add Is_Enum_Array_Aggregate
and Is_Parenthesis_Aggregate field to N_Aggregate.
* libgnarl/s-interr.adb (User_Handler, User_Entry, Blocked)
(Ignored, Last_Unblocker, Server_ID): Likewise.
* libgnarl/s-intman.ads (Keep_Unmasked, Reserve): Likewise.
* libgnarl/s-intman__posix.adb (Exception_Interrupts)
(Initialize): Likewise.
* libgnarl/s-mudido__affinity.adb (Create): Likewise.
* libgnarl/s-osinte__linux.ads (Unmasked, Reserved): Likewise.
* libgnarl/s-taprop__linux.adb (Create_Task, Set_Task_Affinity)
* libgnarl/s-tasdeb.adb (Trace_On): Likewise.
* libgnarl/s-tasdeb.ads (Known_Tasks): Likewise.
* libgnarl/s-tasinf__linux.ads (Any_CPU, No_CPU): Likewise.
* libgnarl/s-taskin.adb (Initialize_ATCB): Likewise.
* libgnarl/s-taskin.ads (Ada_Task_Control_Block): Likewise.
* libgnarl/s-tasren.adb (Default_Treatment)
(New_State): Likewise.
* libgnarl/s-tassta.adb (Trace_Unhandled_Exception_In_Task):
Likewise.
* libgnarl/s-tataat.adb (Index_Array): Likewise.
* libgnarl/s-tpobop.adb (New_State): Likewise.
* libgnat/a-calend.adb (Cumulative_Days_Before_Month)
(Leap_Second_Times): Likewise.
* libgnat/a-calend.ads (Days_In_Month): Likewise.
* libgnat/a-cfinve.adb (Insert): Likewise.
* libgnat/a-chahan.adb (Char_Map): Likewise.
* libgnat/a-chtgbo.adb (Clear): Likewise.
* libgnat/a-cobove.adb ("&", Insert, To_Vector): Likewise.
* libgnat/a-cofove.adb (Insert, To_Vector): Likewise.
* libgnat/a-cohata.ads (Hash_Table_Type): Likewise.
* libgnat/a-coinve.adb (Merge, Insert, Insert_Space): Likewise.
* libgnat/a-convec.adb (Insert, To_Vector): Likewise.
* libgnat/a-coprnu.ads (Primes): Likewise.
* libgnat/a-direct.adb (Empty_String): Use regular "" instead
of aggregate.
(Start_Search_Internal, Name_Case_Equivalence, Search)
(Start_Search, Start_Search_Internal): Use bracket for
aggregate.
* libgnat/a-direct.ads (Start_Search,Search): Likewise.
* libgnat/a-direio.adb (Zeroes): Likewise.
* libgnat/a-nbnbre.adb (Leading_Padding, Trailing_Padding)
(Numerator_Image): Likewise.
* libgnat/a-ngrear.adb (Jacobi): Likewise.
* libgnat/a-stbubo.adb (Get_UTF_8): Likewise.
* libgnat/a-stbufo.adb (Put): Likewise.
* libgnat/a-stbuun.adb (Get_UTF_8): Likewise.
* libgnat/a-stbuut.adb (Put_7bit, Put_Character)
(Put_Wide_Character, Put_Wide_Wide_Character): Likewise.
* libgnat/a-stmaco.ads (Control_Set,Graphic_Set,Letter_Set)
(Lower_Set, Upper_Set, Basic_Set, Decimal_Digit_Set)
(Hexadecimal_Digit_Set, Alphanumeric_Set, Special_Set)
(ISO_646_Set): Likewise.
* libgnat/a-strbou.ads (Insert, Tail, "*", Replicate)
(Null_Bounded_String): Likewise.
* libgnat/a-strfix.ads (Head, Tail): Likewise.
* libgnat/a-strmap.adb (To_Domain, Lemma_Is_Sorted): Likewise.
* libgnat/a-strmap.ads (Null_Set): Likewise.
* libgnat/a-strsup.adb (Super_Head, Super_Replicate)
(Super_Tail): Likewise.
* libgnat/a-strsup.ads (Super_Head, Super_Tail, Times)
(Super_Replicate): Likewise.
* libgnat/a-sttebu.adb (Put_UTF8, Wide_Put_UTF_16): Likewise.
* libgnat/a-stuten.ads (BOM_16): Likewise.
* libgnat/a-stwibo.ads (Null_Bounded_Wide_String): Likewise.
* libgnat/a-stwima.ads (Null_Range): Likewise.
* libgnat/a-stwisu.adb (Super_Head, Super_Replicate)
(Super_Tail): Likewise.
* libgnat/a-stzbou.ads
(Null_Bounded_Wide_Wide_String): Likewise.
* libgnat/a-stzmap.ads (Null_Range): Likewise.
* libgnat/a-stzsup.adb (Super_Head, Super_Replicate)
(Super_Tail, Super_Trim): Likewise.
* libgnat/a-swmwco.ads (Control_Ranges, Graphic_Ranges)
(Letter_Ranges, Lower_Ranges, Upeer_Ranges, Basic_Ranges)
(Decimal_Digit_Ranges, Hexadecimal_Digit_Ranges)
(Alphanumeric_Ranges, Special_Graphic_Ranges, ISO_646_Ranges)
(Character_Ranges, Lower_Case_Mapping, Upper_Case_Mapping)
(Basic_Mapping): Likewise.
* libgnat/a-szmzco.ads (Control_Ranges, Graphic_Ranges)
(Letter_Ranges, Lower_Ranges, Upeer_Ranges, Basic_Ranges)
(Decimal_Digit_Ranges, Hexadecimal_Digit_Ranges)
(Alphanumeric_Ranges, Special_Graphic_Ranges, ISO_646_Ranges)
(Character_Ranges, Lower_Case_Mapping, Upper_Case_Mapping)
(Basic_Mapping): Likewise.
* libgnat/a-teioed.adb (Format_Number): Likewise.
* libgnat/a-wtedit.adb (Format_Number): Likewise.
* libgnat/a-ztedit.adb (Format_Number): Likewise.
* libgnat/g-arrspl.adb (Separators): Likewise.
* libgnat/g-catiio.adb (Month_Name_To_Number): Likewise.
* libgnat/g-cgideb.adb (NL, Title): Likewise.
* libgnat/g-comlin.adb (Internal_Initialize_Option_Scan)
(Display_Section_Help): Likewise.
* libgnat/g-comlin.ads (Opt_Parser_Data): Likewise.
* libgnat/g-debpoo.adb (Set_Dead_Beef, Dump): Likewise.
* libgnat/g-expect.adb (Expect, Has_Process, Send): Likewise.
* libgnat/g-forstr.adb ("+", Get_Formatted): Likewise.
* libgnat/g-memdum.adb (Dump): Likewise.
* libgnat/g-rannum.adb (Image): Likewise.
* libgnat/g-sechas.adb (Final, HMAC_Initial_Context): Likewise.
* libgnat/g-sehamd.ads (Initial_State): Likewise.
* libgnat/g-sehash.ads (Initial_State): Likewise.
* libgnat/g-sercom.ads (Data_Rate_Value): Likewise.
* libgnat/g-sercom__linux.adb (C_Data_Rate, C_Bits, C_Stop_Bits)
(C_Parity): Likewise.
* libgnat/g-shsh32.ads (K, Transform): Likewise.
* libgnat/g-shsh64.ads (K, Transform): Likewise.
* libgnat/g-socket.adb (Levels, Modes, Shutmodes, Requests)
(Options, Flags, Get_Name_Info, Image): Likewise.
* libgnat/g-socket.ads (Inet_Addr_Bytes_Length, Inet_Addr_Type)
(IPv4_To_IPv6_Prefix, Any_Inet_Addr, Any_Inet6_Addr)
(No_Inet_Addr, Broadcast_Inet_Addr, Loopback_Inet_Addr)
(Loopback_Inet6_Addr, Unspecified_Group_Inet_Addr)
(All_Hosts_Group_Inet_Addr, All_Routers_Group_Inet_Addr)
(Unspecified_Group_Inet6_Addr, All_Hosts_Group_Inet6_Addr)
(All_Routers_Group_Inet6_Addr): Likewise.
* libgnat/g-socpol.adb (To_C, Status, Get_Events): Likewise.
* libgnat/g-socpol.ads (Input_Event, Output_Event, Both_Event)
(Error_Event): Likewise.
* libgnat/g-sothco.ads (Families, Lengths, Sockaddr): Likewise.
* libgnat/g-spipat.adb (OK_For_Simple_Arbno): Likewise.
* libgnat/i-cobol.ads (Ada_To_COBOL, COBOL_To_Ada): Likewise.
* libgnat/i-pacdec.adb (Packed_Byte): Likewise.
* libgnat/i-pacdec.ads (Packed_Size): Likewise.
* libgnat/s-bitops.adb (Masks): Likewise.
* libgnat/s-crc32.adb (Table): Likewise.
* libgnat/s-gearop.adb (Unit_Matrix, Unit_Vector): Likewise.
* libgnat/s-genbig.adb (Out_data, Zero_Data, Big_Exp, Big_Mul)
(To_Bignum, To_String, Image, Leading_Padding): Likewise.
* libgnat/s-htable.adb (Reset): Likewise.
* libgnat/s-imgcha.adb (C0, C1): Likewise.
* libgnat/s-powflt.ads (Powten): Likewise.
* libgnat/s-powlfl.ads (Powten): Likewise.
* libgnat/s-powllf.ads (Powten): Likewise.
* libgnat/s-rannum.adb (Matrix_A, Random_Float_Template, Image):
Likewise.
* libgnat/s-rannum.ads (Generator): Likewise.
* libgnat/s-regexp.adb (Compile,Create_Primary_Table)
(Create_Primary_Table_Glob, Create_Secondary_Table, Compile):
Likewise.
* libgnat/s-regpat.adb (Bit_Conversion, Set, Dump_Until)
(Dump_Current, Dump_Error, Try, Reset_Class): Likewise.
* libgnat/s-regpat.ads (Pattern_Matcher, Never_Match): Likewise.
* libgnat/s-scaval__128.adb (Initialize): Likewise.
* libgnat/s-statxd.adb (Fields, W_F, W_LF)
(W_LLF, W_SF): Likewise.
* libgnat/s-stausa.adb (Initialize, Initialize_Analyzer)
(Output_Results): Likewise.
* libgnat/s-strops.adb (Str_Concat_SC): Likewise.
* libgnat/s-valrea.adb (Maxexp32, Maxexp64, Maxexp80): Likewise.
* libgnat/s-wchcon.ads (WC_Encoding_Letters)
(WC_Longest_Sequences): Likewise.
* par-ch4.adb (P_Aggregate_Or_Paren_Expr): Set
Is_Parenthesis_Aggregate when creating a N_Aggregate using
parenthesis.
* scng.adb (Scan): Lower version needed for bracket syntax from
Extensions to Ada2022.
* sem_aggr.adb (Resolve_Aggregate): Raise error for container
aggregate using parenthesis instead of bracket.
(Resolve_Array_Aggregate): Raise warning for aggregate using
parenthesis in Ada2022 with obsolescent warning enabled and not
in GNAT mode.
* sem_util.ads (Check_Ambiguous_Aggregate): Typo fix in comment.

108 files changed:
gcc/ada/exp_imgv.adb
gcc/ada/gen_il-fields.ads
gcc/ada/gen_il-gen-gen_nodes.adb
gcc/ada/libgnarl/s-interr.adb
gcc/ada/libgnarl/s-intman.ads
gcc/ada/libgnarl/s-intman__posix.adb
gcc/ada/libgnarl/s-mudido__affinity.adb
gcc/ada/libgnarl/s-osinte__linux.ads
gcc/ada/libgnarl/s-taprop__linux.adb
gcc/ada/libgnarl/s-tasdeb.adb
gcc/ada/libgnarl/s-tasdeb.ads
gcc/ada/libgnarl/s-tasinf__linux.ads
gcc/ada/libgnarl/s-taskin.adb
gcc/ada/libgnarl/s-taskin.ads
gcc/ada/libgnarl/s-tasren.adb
gcc/ada/libgnarl/s-tassta.adb
gcc/ada/libgnarl/s-tataat.adb
gcc/ada/libgnarl/s-tpobop.adb
gcc/ada/libgnat/a-calend.adb
gcc/ada/libgnat/a-calend.ads
gcc/ada/libgnat/a-cfinve.adb
gcc/ada/libgnat/a-chahan.adb
gcc/ada/libgnat/a-chtgbo.adb
gcc/ada/libgnat/a-cobove.adb
gcc/ada/libgnat/a-cofove.adb
gcc/ada/libgnat/a-cohata.ads
gcc/ada/libgnat/a-coinve.adb
gcc/ada/libgnat/a-convec.adb
gcc/ada/libgnat/a-coprnu.ads
gcc/ada/libgnat/a-direct.adb
gcc/ada/libgnat/a-direct.ads
gcc/ada/libgnat/a-direio.adb
gcc/ada/libgnat/a-nbnbre.adb
gcc/ada/libgnat/a-ngrear.adb
gcc/ada/libgnat/a-stbubo.adb
gcc/ada/libgnat/a-stbufo.adb
gcc/ada/libgnat/a-stbuun.adb
gcc/ada/libgnat/a-stbuut.adb
gcc/ada/libgnat/a-stmaco.ads
gcc/ada/libgnat/a-strbou.ads
gcc/ada/libgnat/a-strfix.ads
gcc/ada/libgnat/a-strmap.adb
gcc/ada/libgnat/a-strmap.ads
gcc/ada/libgnat/a-strsup.adb
gcc/ada/libgnat/a-strsup.ads
gcc/ada/libgnat/a-sttebu.adb
gcc/ada/libgnat/a-stuten.ads
gcc/ada/libgnat/a-stwibo.ads
gcc/ada/libgnat/a-stwima.ads
gcc/ada/libgnat/a-stwisu.adb
gcc/ada/libgnat/a-stzbou.ads
gcc/ada/libgnat/a-stzmap.ads
gcc/ada/libgnat/a-stzsup.adb
gcc/ada/libgnat/a-swmwco.ads
gcc/ada/libgnat/a-szmzco.ads
gcc/ada/libgnat/a-teioed.adb
gcc/ada/libgnat/a-wtedit.adb
gcc/ada/libgnat/a-ztedit.adb
gcc/ada/libgnat/g-arrspl.adb
gcc/ada/libgnat/g-catiio.adb
gcc/ada/libgnat/g-cgideb.adb
gcc/ada/libgnat/g-comlin.adb
gcc/ada/libgnat/g-comlin.ads
gcc/ada/libgnat/g-debpoo.adb
gcc/ada/libgnat/g-expect.adb
gcc/ada/libgnat/g-forstr.adb
gcc/ada/libgnat/g-memdum.adb
gcc/ada/libgnat/g-rannum.adb
gcc/ada/libgnat/g-sechas.adb
gcc/ada/libgnat/g-sehamd.ads
gcc/ada/libgnat/g-sehash.ads
gcc/ada/libgnat/g-sercom.ads
gcc/ada/libgnat/g-sercom__linux.adb
gcc/ada/libgnat/g-shsh32.ads
gcc/ada/libgnat/g-shsh64.ads
gcc/ada/libgnat/g-socket.adb
gcc/ada/libgnat/g-socket.ads
gcc/ada/libgnat/g-socpol.adb
gcc/ada/libgnat/g-socpol.ads
gcc/ada/libgnat/g-sothco.ads
gcc/ada/libgnat/g-spipat.adb
gcc/ada/libgnat/i-cobol.ads
gcc/ada/libgnat/i-pacdec.adb
gcc/ada/libgnat/i-pacdec.ads
gcc/ada/libgnat/s-bitops.adb
gcc/ada/libgnat/s-crc32.adb
gcc/ada/libgnat/s-gearop.adb
gcc/ada/libgnat/s-genbig.adb
gcc/ada/libgnat/s-htable.adb
gcc/ada/libgnat/s-imgcha.adb
gcc/ada/libgnat/s-powflt.ads
gcc/ada/libgnat/s-powlfl.ads
gcc/ada/libgnat/s-powllf.ads
gcc/ada/libgnat/s-rannum.adb
gcc/ada/libgnat/s-rannum.ads
gcc/ada/libgnat/s-regexp.adb
gcc/ada/libgnat/s-regpat.adb
gcc/ada/libgnat/s-regpat.ads
gcc/ada/libgnat/s-scaval__128.adb
gcc/ada/libgnat/s-statxd.adb
gcc/ada/libgnat/s-stausa.adb
gcc/ada/libgnat/s-strops.adb
gcc/ada/libgnat/s-valrea.adb
gcc/ada/libgnat/s-wchcon.ads
gcc/ada/par-ch4.adb
gcc/ada/scng.adb
gcc/ada/sem_aggr.adb
gcc/ada/sem_util.ads

index 69b9f2df04ef27a706fef144c76090966631f9fd..f2c51291d077a8640beceea73bbf23296a7f3605 100644 (file)
@@ -159,7 +159,8 @@ package body Exp_Imgv is
                    Make_Component_Definition (Loc,
                      Aliased_Present    => False,
                      Subtype_Indication => New_Occurrence_Of (Ctyp, Loc))),
-             Expression          => Make_Aggregate (Loc, Expressions => V)));
+             Expression          => Make_Aggregate (Loc, Expressions => V,
+                                      Is_Enum_Array_Aggregate => True)));
       end Append_Table_To;
 
    --  Start of Build_Enumeration_Image_Tables
index f3f3ca42703252e9215347f971d39098699695aa..ca3439e2e84b34b59132755a9ba5c84a5ae72b70 100644 (file)
@@ -258,6 +258,8 @@ package Gen_IL.Fields is
       Is_Folded_In_Parser,
       Is_Generic_Contract_Pragma,
       Is_Homogeneous_Aggregate,
+      Is_Parenthesis_Aggregate,
+      Is_Enum_Array_Aggregate,
       Is_Ignored,
       Is_Ignored_Ghost_Pragma,
       Is_In_Discriminant_Check,
index 9937919f8acd986d3871a8bb2c93ec13b1d7d6db..9f9fef9a186f1dbff3ebb68069019b168aa1e342 100644 (file)
@@ -481,7 +481,9 @@ begin -- Gen_IL.Gen.Gen_Nodes
        (Sy (Expressions, List_Id, Default_No_List),
         Sy (Component_Associations, List_Id, Default_No_List),
         Sy (Null_Record_Present, Flag),
+        Sy (Is_Parenthesis_Aggregate, Flag),
         Sy (Is_Homogeneous_Aggregate, Flag),
+        Sy (Is_Enum_Array_Aggregate, Flag),
         Sm (Aggregate_Bounds, Node_Id),
         Sm (Entity_Or_Associated_Node, Node_Id), -- just Associated_Node
         Sm (Compile_Time_Known_Aggregate, Flag),
index 7d36b9f224e35844609a301d5205419bf5d289c7..dc1ed1727a8380cd85ee6e7f63e86952f9710ba5 100644 (file)
@@ -159,7 +159,7 @@ package body System.Interrupts is
    end record;
 
    User_Handler : array (Interrupt_ID'Range) of Handler_Assoc :=
-                    (others => (null, Static => False));
+                    [others => (null, Static => False)];
    pragma Volatile_Components (User_Handler);
    --  Holds the protected procedure handler (if any) and its Static
    --  information for each interrupt. A handler is a Static one if it is
@@ -167,27 +167,27 @@ package body System.Interrupts is
    --  not static)
 
    User_Entry : array (Interrupt_ID'Range) of Entry_Assoc :=
-                  (others => (T => Null_Task, E => Null_Task_Entry));
+                  [others => (T => Null_Task, E => Null_Task_Entry)];
    pragma Volatile_Components (User_Entry);
    --  Holds the task and entry index (if any) for each interrupt
 
-   Blocked : array (Interrupt_ID'Range) of Boolean := (others => False);
+   Blocked : array (Interrupt_ID'Range) of Boolean := [others => False];
    pragma Atomic_Components (Blocked);
    --  True iff the corresponding interrupt is blocked in the process level
 
-   Ignored : array (Interrupt_ID'Range) of Boolean := (others => False);
+   Ignored : array (Interrupt_ID'Range) of Boolean := [others => False];
    pragma Atomic_Components (Ignored);
    --  True iff the corresponding interrupt is blocked in the process level
 
    Last_Unblocker :
-     array (Interrupt_ID'Range) of Task_Id := (others => Null_Task);
+     array (Interrupt_ID'Range) of Task_Id := [others => Null_Task];
    pragma Atomic_Components (Last_Unblocker);
    --  Holds the ID of the last Task which Unblocked this Interrupt. It
    --  contains Null_Task if no tasks have ever requested the Unblocking
    --  operation or the Interrupt is currently Blocked.
 
    Server_ID : array (Interrupt_ID'Range) of Task_Id :=
-                 (others => Null_Task);
+                 [others => Null_Task];
    pragma Atomic_Components (Server_ID);
    --  Holds the Task_Id of the Server_Task for each interrupt. Task_Id is
    --  needed to accomplish locking per Interrupt base. Also is needed to
index c49316301e065d61e08ce75f0c126ca4d80892da..663aed94ebcb57ce1a60fed9b5d11e2e8f24eb09 100644 (file)
@@ -74,7 +74,7 @@ package System.Interrupt_Management is
    --  The interrupt that is used to implement task abort if an interrupt is
    --  used for that purpose. This is one of the reserved interrupts.
 
-   Keep_Unmasked : Interrupt_Set := (others => False);
+   Keep_Unmasked : Interrupt_Set := [others => False];
    --  Keep_Unmasked (I) is true iff the interrupt I is one that must be kept
    --  unmasked at all times, except (perhaps) for short critical sections.
    --  This includes interrupts that are mapped to exceptions (see
@@ -83,7 +83,7 @@ package System.Interrupt_Management is
    --  reasons. Where interrupts are implemented as OS signals, and signal
    --  masking is per-task, the interrupt should be unmasked in ALL TASKS.
 
-   Reserve : Interrupt_Set := (others => False);
+   Reserve : Interrupt_Set := [others => False];
    --  Reserve (I) is true iff the interrupt I is one that cannot be permitted
    --  to be attached to a user handler. The possible reasons are many. For
    --  example, it may be mapped to an exception used to implement task abort,
index ae3d77eaf6794b0dfae7c45c64ea14e1f45de786..f0f65cdb0ce09255b99ffc4d4aaa42c2c2df0dd7 100644 (file)
@@ -66,7 +66,7 @@ package body System.Interrupt_Management is
 
    type Interrupt_List is array (Interrupt_ID range <>) of Interrupt_ID;
    Exception_Interrupts : constant Interrupt_List :=
-     (SIGFPE, SIGILL, SIGSEGV, SIGBUS);
+     [SIGFPE, SIGILL, SIGSEGV, SIGBUS];
 
    Unreserve_All_Interrupts : constant Interfaces.C.int;
    pragma Import
@@ -206,8 +206,8 @@ package body System.Interrupt_Management is
 
       act.sa_mask := Signal_Mask;
 
-      pragma Assert (Keep_Unmasked = (Interrupt_ID'Range => False));
-      pragma Assert (Reserve = (Interrupt_ID'Range => False));
+      pragma Assert (Keep_Unmasked = [Interrupt_ID'Range => False]);
+      pragma Assert (Reserve = [Interrupt_ID'Range => False]);
 
       --  Process state of exception signals
 
index 5a9ccafafefd237b428ff376308d731b41664980..7118a1d2d343e247a18a19b20c04ceaf9c963783 100644 (file)
@@ -113,7 +113,7 @@ package body System.Multiprocessors.Dispatching_Domains is
 
    function Create (First : CPU; Last : CPU_Range) return Dispatching_Domain is
    begin
-      return Create ((First .. Last => True));
+      return Create ([First .. Last => True]);
    end Create;
 
    function Create (Set : CPU_Set) return Dispatching_Domain is
@@ -156,7 +156,7 @@ package body System.Multiprocessors.Dispatching_Domains is
            ST.System_Domain (Rng);
          Actual : constant ST.Dispatching_Domain :=
            ST_DD_Slice and not System_Domain_Slice;
-         Expected : constant ST.Dispatching_Domain := (Rng => False);
+         Expected : constant ST.Dispatching_Domain := [Rng => False];
       begin
          if Actual /= Expected then
             raise Dispatching_Domain_Error with
@@ -184,7 +184,7 @@ package body System.Multiprocessors.Dispatching_Domains is
 
       New_System_Domain (Rng) := New_System_Domain (Rng) and not ST_DD_Slice;
 
-      if New_System_Domain = (New_System_Domain'Range => False) then
+      if New_System_Domain = [New_System_Domain'Range => False] then
          raise Dispatching_Domain_Error with
            "would leave System_Dispatching_Domain empty";
       end if;
index cda0f8ef1032c58ba6bb9ec2b5f67562226a9b84..4f682e039f33488a4de752068034f11d0b5cdeed 100644 (file)
@@ -132,7 +132,7 @@ package System.OS_Interface is
 
    type Signal_Set is array (Natural range <>) of Signal;
 
-   Unmasked : constant Signal_Set := (
+   Unmasked : constant Signal_Set := [
       SIGTRAP,
       --  To enable debugging on multithreaded applications, mark SIGTRAP to
       --  be kept unmasked.
@@ -148,9 +148,9 @@ package System.OS_Interface is
 
       SIGKILL, SIGSTOP
       --  These two signals actually can't be masked (POSIX won't allow it)
-      );
+      ];
 
-   Reserved : constant Signal_Set := (
+   Reserved : constant Signal_Set := [
       SIG32, SIG33, SIG34
       --  glibc POSIX threads implementation uses two (NPTL) or three
       --  (LinuxThreads) real-time signals for its own use (see SIGNAL(7)).
@@ -158,7 +158,7 @@ package System.OS_Interface is
       --  not permit these signals to be used by the public signal.h API.
       --  While LinuxThreads is mostly likely unused now, SIG34 is still
       --  reserved as this behavior is consistent with past GNAT releases.
-      );
+      ];
 
    type sigset_t is private;
 
index 1c8c6bd38dc1d29b1a65563820a4796cdf1d7fb5..273893464fe1090222ae651ccf9711c4c53569fc 100644 (file)
@@ -973,8 +973,8 @@ package body System.Task_Primitives.Operations is
       elsif T.Common.Domain /= null and then
         (T.Common.Domain /= ST.System_Domain
           or else T.Common.Domain.all /=
-                    (Multiprocessors.CPU'First ..
-                     Multiprocessors.Number_Of_CPUs => True))
+                    [Multiprocessors.CPU'First ..
+                     Multiprocessors.Number_Of_CPUs => True])
       then
          declare
             CPUs    : constant size_t :=
@@ -1494,8 +1494,8 @@ package body System.Task_Primitives.Operations is
             elsif T.Common.Domain /= null and then
               (T.Common.Domain /= ST.System_Domain
                 or else T.Common.Domain.all /=
-                          (Multiprocessors.CPU'First ..
-                           Multiprocessors.Number_Of_CPUs => True))
+                          [Multiprocessors.CPU'First ..
+                           Multiprocessors.Number_Of_CPUs => True])
             then
                --  Set the affinity to all the processors belonging to the
                --  dispatching domain. To avoid changing CPU affinities when
index d4f37f09b8531ba02f66031785fb4f5857262763..edb2503ee26820d9fd2dc19ea65ad6d678cf8d83 100644 (file)
@@ -54,7 +54,7 @@ package body System.Tasking.Debug is
 
    type Trace_Flag_Set is array (Character) of Boolean;
 
-   Trace_On : Trace_Flag_Set := ('A' .. 'Z' => False, others => True);
+   Trace_On : Trace_Flag_Set := ['A' .. 'Z' => False, others => True];
 
    Stderr_Fd : constant := 2;
    --  File descriptor for standard error
index eebb2a9f319cf7e8f4f13a4bbaddf9b803b98a7c..8d75a5e0337c73a9c88a2eaa6a825c9939b7f4d8 100644 (file)
@@ -65,7 +65,7 @@ package System.Tasking.Debug is
    -- General GDB support --
    -------------------------
 
-   Known_Tasks : array (0 .. 999) of Task_Id := (others => null)
+   Known_Tasks : array (0 .. 999) of Task_Id := [others => null]
      with Atomic_Components;
    --  Global array of tasks read by gdb, and updated by Create_Task and
    --  Finalize_TCB. Ensure access to its components is atomic to allow
index e6da7505f14e6a8c7743afbe63a58ac07669732c..f2877e6863ccf847572a929eb665f8a3077b5869 100644 (file)
@@ -79,8 +79,8 @@ package System.Task_Info is
 
    subtype CPU_Set is System.OS_Interface.cpu_set_t;
 
-   Any_CPU : constant CPU_Set := (bits => (others => True));
-   No_CPU  : constant CPU_Set := (bits => (others => False));
+   Any_CPU : constant CPU_Set := (bits => [others => True]);
+   No_CPU  : constant CPU_Set := (bits => [others => False]);
 
    Invalid_CPU_Number : exception;
    --  Raised when an invalid CPU mask has been specified
index 1e6f42da39301088919abf8f09f91e8fa7f20aba..478809c3547002f39a0fd02cc88bdc7e176e2004 100644 (file)
@@ -140,7 +140,7 @@ package body System.Tasking is
       T.Common.Global_Task_Lock_Nesting := 0;
       T.Common.Fall_Back_Handler        := null;
       T.Common.Specific_Handler         := null;
-      T.Common.Debug_Events             := (others => False);
+      T.Common.Debug_Events             := [others => False];
       T.Common.Task_Image_Len           := 0;
 
       if T.Common.Parent = null then
index 1751553c58c467f3479ee452ac448c1225f95838..0073c1979a517fb1190f7422453e95b7eb2e95bb 100644 (file)
@@ -1157,7 +1157,7 @@ package System.Tasking is
       --  non-terminated task so that the associated storage is automatically
       --  reclaimed when the task terminates.
 
-      Attributes : Attribute_Array := (others => 0);
+      Attributes : Attribute_Array := [others => 0];
       --  Task attributes
 
       --  IMPORTANT Note: the Entry_Queues field is last for efficiency of
index fa10b0cbbbe648e868ae6cf7d8023d6fb05d31ef..7b11d39c9e015b887ea8c096f22180547ef7991e 100644 (file)
@@ -59,28 +59,28 @@ package body System.Tasking.Rendezvous is
    ----------------
 
    Default_Treatment : constant array (Select_Modes) of Select_Treatment :=
-     (Simple_Mode         => No_Alternative_Open,
+     [Simple_Mode         => No_Alternative_Open,
       Else_Mode           => Else_Selected,
       Terminate_Mode      => Terminate_Selected,
-      Delay_Mode          => No_Alternative_Open);
+      Delay_Mode          => No_Alternative_Open];
 
    New_State : constant array (Boolean, Entry_Call_State)
      of Entry_Call_State :=
-       (True =>
-         (Never_Abortable   => Never_Abortable,
+       [True =>
+         [Never_Abortable   => Never_Abortable,
           Not_Yet_Abortable => Now_Abortable,
           Was_Abortable     => Now_Abortable,
           Now_Abortable     => Now_Abortable,
           Done              => Done,
-          Cancelled         => Cancelled),
+          Cancelled         => Cancelled],
         False =>
-         (Never_Abortable   => Never_Abortable,
+         [Never_Abortable   => Never_Abortable,
           Not_Yet_Abortable => Not_Yet_Abortable,
           Was_Abortable     => Was_Abortable,
           Now_Abortable     => Now_Abortable,
           Done              => Done,
-          Cancelled         => Cancelled)
-       );
+          Cancelled         => Cancelled]
+       ];
 
    -----------------------
    -- Local Subprograms --
index bbc7d14d5d8ad9e1680afd7f710b6fbe84fe9b6a..245145cf67ea7b11cbb061109f0ab7e6ab4f944c 100644 (file)
@@ -1462,7 +1462,7 @@ package body System.Tasking.Stages is
 
       To_Stderr (System.Address_Image (To_Address (Self_Id)));
       To_Stderr (" terminated by unhandled exception");
-      To_Stderr ((1 => ASCII.LF));
+      To_Stderr ([ASCII.LF]);
       To_Stderr (Exception_Information (Excep.all));
       Initialization.Task_Unlock (Self_Id);
    end Trace_Unhandled_Exception_In_Task;
index d3b23bb8c6b5f91b3dde734713a2e80b50aa5fb9..ebc16e9a1a3f1c7330f4077ed3a93b23429c4afa 100644 (file)
@@ -47,7 +47,7 @@ package body System.Tasking.Task_Attributes is
    end record;
 
    Index_Array : array (1 .. Max_Attribute_Count) of Index_Info :=
-                   (others => (False, False));
+                   [others => (False, False)];
 
    --  Note that this package will use an efficient implementation with no
    --  locks and no extra dynamic memory allocation if Attribute can fit in a
index 5739eaa030b8967853762d657a53fe35dc312e4f..90e45e99760eaa293b90c78748aa0f39d9c58487 100644 (file)
@@ -942,21 +942,21 @@ package body System.Tasking.Protected_Objects.Operations is
 
    New_State : constant array (Boolean, Entry_Call_State)
      of Entry_Call_State :=
-       (True =>
-         (Never_Abortable   => Never_Abortable,
+       [True =>
+         [Never_Abortable   => Never_Abortable,
           Not_Yet_Abortable => Now_Abortable,
           Was_Abortable     => Now_Abortable,
           Now_Abortable     => Now_Abortable,
           Done              => Done,
-          Cancelled         => Cancelled),
+          Cancelled         => Cancelled],
         False =>
-         (Never_Abortable   => Never_Abortable,
+         [Never_Abortable   => Never_Abortable,
           Not_Yet_Abortable => Not_Yet_Abortable,
           Was_Abortable     => Was_Abortable,
           Now_Abortable     => Now_Abortable,
           Done              => Done,
-          Cancelled         => Cancelled)
-       );
+          Cancelled         => Cancelled]
+       ];
 
    procedure Update_For_Queue_To_PO
      (Entry_Call : Entry_Call_Link;
index b24e95d88665a89f2a9567f5f7a1ee5b84a3596f..3d7ae902c0daa0ec466d6cefd9973f81257d5ba2 100644 (file)
@@ -206,14 +206,14 @@ is
 
    Cumulative_Days_Before_Month :
      constant array (Month_Number) of Natural :=
-       (0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334);
+       [0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334];
 
    --  The following table contains the hard time values of all existing leap
    --  seconds. The values are produced by the utility program xleaps.adb. This
    --  must be updated when additional leap second times are defined.
 
    Leap_Second_Times : constant array (1 .. Leap_Seconds_Count) of Time_Rep :=
-     (-5601484800000000000,
+     [-5601484800000000000,
       -5585587199000000000,
       -5554051198000000000,
       -5522515197000000000,
@@ -239,7 +239,7 @@ is
       -4449513577000000000,
       -4339180776000000000,
       -4244572775000000000,
-      -4197052774000000000);
+      -4197052774000000000];
 
    ---------
    -- "+" --
index cd3fed53a9ac363fde1719a36d96660c055fe841..caca8da53bb4f8922dc81bc1637c296075a80588 100644 (file)
@@ -242,7 +242,7 @@ private
    --  epoch) expressed in nanoseconds. Note that year 2100 is non-leap.
 
    Days_In_Month : constant array (Month_Number) of Day_Number :=
-                     (31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31);
+                     [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
    --  Days in month for non-leap year, leap year case is adjusted in code
 
    Invalid_Time_Zone_Offset : Long_Integer;
index d0c7e82ac8f9f95d6a67cc2aa5c32ad5c2e5a2c1..4770608efcddf291d5fffbf7c2d1127d5b9a2124 100644 (file)
@@ -871,7 +871,7 @@ is
 
       J := To_Array_Index (Before);
 
-      Elems (Container) (J .. J - 1 + Count) := (others => H (New_Item));
+      Elems (Container) (J .. J - 1 + Count) := [others => H (New_Item)];
    end Insert;
 
    procedure Insert
@@ -1445,7 +1445,7 @@ is
            (Capacity     => Length,
             Last         => Last,
             Elements_Ptr => <>,
-            Elements     => (others => H (New_Item)));
+            Elements     => [others => H (New_Item)]);
       end;
    end To_Vector;
 
index 411d485db60d49eabd4878abd31c46afab2382ea..387af423b7eb776aeedff48ebe7de45f21c41ec7 100644 (file)
@@ -64,7 +64,7 @@ is
    Graphic    : constant Character_Flags := Alphanum or Special;
 
    Char_Map : constant array (Character) of Character_Flags :=
-   (
+   [
      NUL                         => Control,
      SOH                         => Control,
      STX                         => Control,
@@ -282,7 +282,7 @@ is
      LC_Y_Acute                  => Lower,
      LC_Icelandic_Thorn          => Lower + Basic,
      LC_Y_Diaeresis              => Lower
-   );
+   ];
 
    ---------------------
    -- Is_Alphanumeric --
index 678cdc0d522ac3a88867c8f9ab54763ee2cf0b75..e6db47f5bc6802484b5de2788a9797e186240181 100644 (file)
@@ -60,7 +60,7 @@ package body Ada.Containers.Hash_Tables.Generic_Bounded_Operations is
       --  HT.Busy := 0;
       --  HT.Lock := 0;
       HT.Free := -1;
-      HT.Buckets := (others => 0);  -- optimize this somehow ???
+      HT.Buckets := [others => 0];  -- optimize this somehow ???
    end Clear;
 
    --------------------------
index e56cb94610e15638e597c8ba42b00e01d8f7864d..f340f23b7c99a5d64dbb67b245ba3a0b3452e502 100644 (file)
@@ -258,7 +258,7 @@ package body Ada.Containers.Bounded_Vectors is
       end if;
 
       return Vector'(Capacity => 2,
-                     Elements => (Left, Right),
+                     Elements => [Left, Right],
                      Last     => Index_Type'First + 1,
                      others   => <>);
    end "&";
@@ -1227,7 +1227,7 @@ package body Ada.Containers.Bounded_Vectors is
          --  The new items are being appended to the vector, so no
          --  sliding of existing elements is required.
 
-         EA (J .. New_Length) := (others => New_Item);
+         EA (J .. New_Length) := [others => New_Item];
 
       else
          --  The new items are being inserted before some existing
@@ -1235,7 +1235,7 @@ package body Ada.Containers.Bounded_Vectors is
          --  new home.
 
          EA (J + Count .. New_Length) := EA (J .. Old_Length);
-         EA (J .. J + Count - 1) := (others => New_Item);
+         EA (J .. J + Count - 1) := [others => New_Item];
       end if;
 
       if Index_Type'Base'Last >= Count_Type'Pos (Count_Type'Last) then
@@ -2770,7 +2770,7 @@ package body Ada.Containers.Bounded_Vectors is
       end if;
 
       return V : Vector (Capacity => Length) do
-         V.Elements := (others => New_Item);
+         V.Elements := [others => New_Item];
          V.Last := Last;
       end return;
    end To_Vector;
index c7f4f06005e0abc0accff29756e9b8530e2185a1..4031e992b552d68c18dabc66563e5ff218f9c8bc 100644 (file)
@@ -763,7 +763,7 @@ is
 
       J := To_Array_Index (Before);
 
-      Container.Elements (J .. J - 1 + Count) := (others => New_Item);
+      Container.Elements (J .. J - 1 + Count) := [others => New_Item];
    end Insert;
 
    procedure Insert
@@ -1304,7 +1304,7 @@ is
          return
            (Capacity => Length,
             Last     => Last,
-            Elements => (others => New_Item));
+            Elements => [others => New_Item]);
       end;
    end To_Vector;
 
index f7e44a33685fc23d749a160dc6c046dcc55dd459..a52f542329daf1c22ae262d291efea8233e442fb 100644 (file)
@@ -73,7 +73,7 @@ package Ada.Containers.Hash_Tables is
          TC      : aliased Helpers.Tamper_Counts;
          Free    : Count_Type'Base             := -1;
          Nodes   : Nodes_Type (1 .. Capacity);
-         Buckets : Buckets_Type (1 .. Modulus) := (others => 0);
+         Buckets : Buckets_Type (1 .. Modulus) := [others => 0];
       end record;
 
       package Implementation is new Helpers.Generic_Implementation;
index 9df6e3d48815d121197585dd08d3756c21dfb76f..7ed88a5b55e708f16f48c856dba75fee7127ace1 100644 (file)
@@ -1027,7 +1027,7 @@ is
                              SA (Index_Type'First .. Source.Last);
                   begin
                      TA (Index_Type'First .. J) := Src;
-                     Src := (others => null);
+                     Src := [others => null];
                   end;
 
                   Source.Last := No_Index;
@@ -1472,7 +1472,7 @@ is
                      --  we started by clearing out all of the stale values,
                      --  leaving a "hole" in the middle of the array.
 
-                     E (K .. Index - 1) := (others => null);
+                     E (K .. Index - 1) := [others => null];
                      raise;
                end;
             end if;
@@ -2157,7 +2157,7 @@ is
                end if;
 
                E (Index .. New_Last) := E (Before .. Container.Last);
-               E (Before .. Index - 1) := (others => null);
+               E (Before .. Index - 1) := [others => null];
             end if;
          end;
 
index 5cede720ffd874d31a3d943fde62ae6f80ff163a..6f39ceb2138163c4e6cd9acfa6dda2011a9298d8 100644 (file)
@@ -1161,7 +1161,7 @@ is
 
          Container.Elements := new Elements_Type'
                                      (Last => New_Last,
-                                      EA   => (others => New_Item));
+                                      EA   => [others => New_Item]);
 
          --  The allocation of the new, internal array succeeded, so it is now
          --  safe to update the Last index, restoring container invariants.
@@ -1189,7 +1189,7 @@ is
                --  The new items are being appended to the vector, so no
                --  sliding of existing elements is required.
 
-               EA (Before .. New_Last) := (others => New_Item);
+               EA (Before .. New_Last) := [others => New_Item];
 
             else
                --  The new items are being inserted before some existing
@@ -1204,7 +1204,7 @@ is
                end if;
 
                EA (Index .. New_Last) := EA (Before .. Container.Last);
-               EA (Before .. Index - 1) := (others => New_Item);
+               EA (Before .. Index - 1) := [others => New_Item];
             end if;
          end;
 
@@ -1270,7 +1270,7 @@ is
            SA (Index_Type'First .. Before - 1);
 
          if Before > Container.Last then
-            DA (Before .. New_Last) := (others => New_Item);
+            DA (Before .. New_Last) := [others => New_Item];
 
          else
             --  The new items are being inserted before some existing elements,
@@ -1282,7 +1282,7 @@ is
                Index := Index_Type'Base (Count_Type'Base (Before) + Count);
             end if;
 
-            DA (Before .. Index - 1) := (others => New_Item);
+            DA (Before .. Index - 1) := [others => New_Item];
             DA (Index .. New_Last) := SA (Before .. Container.Last);
          end if;
 
@@ -3265,7 +3265,7 @@ is
          Last := Index_Type'Base (Count_Type'Base (No_Index) + Length);
       end if;
 
-      Elements := new Elements_Type'(Last, EA => (others => New_Item));
+      Elements := new Elements_Type'(Last, EA => [others => New_Item]);
 
       return (Controlled with Elements, Last, TC => <>);
    end To_Vector;
index 7f5f7bd971afc18b8782ea1432ab72e0e065bc1e..8a267fb3fbaa4a177ec5f15b4e7ba3b5ba2c819c 100644 (file)
@@ -38,12 +38,12 @@ package Ada.Containers.Prime_Numbers is
    type Primes_Type is array (Positive range <>) of Hash_Type;
 
    Primes : constant Primes_Type :=
-     (53,         97,         193,       389,       769,
+     [53,         97,         193,       389,       769,
       1543,       3079,       6151,      12289,     24593,
       49157,      98317,      196613,    393241,    786433,
       1572869,    3145739,    6291469,   12582917,  25165843,
       50331653,   100663319,  201326611, 402653189, 805306457,
-      1610612741, 3221225473, 4294967291);
+      1610612741, 3221225473, 4294967291];
 
    function To_Prime (Length : Count_Type) return Hash_Type;
    --  Returns the smallest value in Primes not less than Length
index 20616a25d2d058e199201956b0a91c74f5a4c1dd..41dca3c6a56140a6a1901f3cfbd54749dc0d90f8 100644 (file)
@@ -89,7 +89,7 @@ package body Ada.Directories is
    end record;
    --  The current state of a search
 
-   Empty_String : constant String := (1 .. 0 => ASCII.NUL);
+   Empty_String : constant String := "";
    --  Empty string, returned by function Extension when there is no extension
 
    procedure Free is new Ada.Unchecked_Deallocation (Search_Data, Search_Ptr);
@@ -107,7 +107,7 @@ package body Ada.Directories is
      (Search                 : in out Search_Type;
       Directory              : String;
       Pattern                : String;
-      Filter                 : Filter_Type := (others => True);
+      Filter                 : Filter_Type := [others => True];
       Force_Case_Insensitive : Boolean);
    --  Similar to Start_Search except we can force a search to be
    --  case-insensitive, which is important for detecting the name-case
@@ -1094,7 +1094,7 @@ package body Ada.Directories is
         (Search    => S,
          Directory => To_String (Dir_Path),
          Pattern   => "",
-         Filter    => (Directory => False, others => True));
+         Filter    => [Directory => False, others => True]);
 
       loop
          Get_Next_Entry (S, Test_File);
@@ -1114,7 +1114,7 @@ package body Ada.Directories is
         (Search                 => S,
          Directory              => To_String (Dir_Path),
          Pattern                => Simple_Name (Test_File),
-         Filter                 => (Directory => False, others => True),
+         Filter                 => [Directory => False, others => True],
          Force_Case_Insensitive => True);
 
       --  We will find at least one match due to the search hitting our test
@@ -1215,7 +1215,7 @@ package body Ada.Directories is
    procedure Search
      (Directory : String;
       Pattern   : String;
-      Filter    : Filter_Type := (others => True);
+      Filter    : Filter_Type := [others => True];
       Process   : not null access procedure
                                     (Directory_Entry : Directory_Entry_Type))
    is
@@ -1401,7 +1401,7 @@ package body Ada.Directories is
      (Search    : in out Search_Type;
       Directory : String;
       Pattern   : String;
-      Filter    : Filter_Type := (others => True))
+      Filter    : Filter_Type := [others => True])
    is
    begin
       Start_Search_Internal (Search, Directory, Pattern, Filter, False);
@@ -1415,7 +1415,7 @@ package body Ada.Directories is
      (Search                 : in out Search_Type;
       Directory              : String;
       Pattern                : String;
-      Filter                 : Filter_Type := (others => True);
+      Filter                 : Filter_Type := [others => True];
       Force_Case_Insensitive : Boolean)
    is
       function opendir (file_name : String) return DIRs;
index 12f3bd4a89d0a743588c6a85c3bbe0b5b41a9b4a..a88cd014c23cc54781ec36c9b9cfa57a1f3ae349 100644 (file)
@@ -366,7 +366,7 @@ package Ada.Directories is
      (Search    : in out Search_Type;
       Directory : String;
       Pattern   : String;
-      Filter    : Filter_Type := (others => True));
+      Filter    : Filter_Type := [others => True]);
    --  Starts a search in the directory entry in the directory named by
    --  Directory for entries matching Pattern. Pattern represents a file name
    --  matching pattern. If Pattern is null, all items in the directory are
@@ -407,7 +407,7 @@ package Ada.Directories is
    procedure Search
      (Directory : String;
       Pattern   : String;
-      Filter    : Filter_Type := (others => True);
+      Filter    : Filter_Type := [others => True];
       Process   : not null access procedure
                                     (Directory_Entry : Directory_Entry_Type));
    --  Searches in the directory named by Directory for entries matching
index f83b34b5df41929bf7d02acf93925731a65de674..1258bee9cae6fd6e3f6bf8fbb001a0ab8942273b 100644 (file)
@@ -45,7 +45,7 @@ with Ada.Unchecked_Conversion;
 package body Ada.Direct_IO is
 
    Zeroes : constant System.Storage_Elements.Storage_Array :=
-     (1 .. System.Storage_Elements.Storage_Offset (Bytes) => 0);
+     [1 .. System.Storage_Elements.Storage_Offset (Bytes) => 0];
    --  Buffer used to fill out partial records
 
    package FCB renames System.File_Control_Block;
index e45bc6dd02895b49a17bcf29efa7dd93bb731afd..d1820f4f3dad96af964f616ca01cac0e816ddd76 100644 (file)
@@ -441,8 +441,8 @@ package body Ada.Numerics.Big_Numbers.Big_Reals is
          if Str = "" then
             return Leading_Padding ("0", Min_Length, Char);
          else
-            return (1 .. Integer'Max (Integer (Min_Length) - Str'Length, 0)
-                           => Char) & Str;
+            return [1 .. Integer'Max (Integer (Min_Length) - Str'Length, 0)
+                           => Char] & Str;
          end if;
       end Leading_Padding;
 
@@ -468,8 +468,8 @@ package body Ada.Numerics.Big_Numbers.Big_Reals is
             return Str (Str'First .. Str'First + Length - 1);
          else
             return Str &
-              (1 .. Integer'Max (Integer (Length) - Str'Length, 0)
-                      => Char);
+              [1 .. Integer'Max (Integer (Length) - Str'Length, 0)
+                      => Char];
          end if;
       end Trailing_Padding;
 
@@ -495,7 +495,7 @@ package body Ada.Numerics.Big_Numbers.Big_Reals is
             if Index < 0 then
                return Leading_Padding ("0", Fore)
                  & "."
-                 & Trailing_Padding ((1 .. -Index => '0') & Str, Aft)
+                 & Trailing_Padding ([1 .. -Index => '0'] & Str, Aft)
                  & (if Exp = 0 then "" else "E+" & Image (Natural (Exp)));
             else
                return Leading_Padding (Str (Str'First .. Index), Fore)
index 820e6f75388c5efda67f792398e6f57ab56d0119..5095db8ee65443ba5ac9fb81d42c4ed9988752a2 100644 (file)
@@ -614,7 +614,7 @@ package body Ada.Numerics.Generic_Real_Arrays is
       --        different bounds, so take care indexing elements. Assignment
       --        as a whole is fine as sliding is automatic in that case.
 
-      Vectors := (if not Compute_Vectors then (1 .. 0 => (1 .. 0 => 0.0))
+      Vectors := (if not Compute_Vectors then [1 .. 0 => [1 .. 0 => 0.0]]
                   else Unit_Matrix (Vectors'Length (1), Vectors'Length (2)));
       Values := Diagonal (M);
 
@@ -637,7 +637,7 @@ package body Ada.Numerics.Generic_Real_Arrays is
          --  an absolute value that exceeds the threshold.
 
          Diag := Values;
-         Diag_Adj := (others => 0.0); -- Accumulates adjustments to Diag
+         Diag_Adj := [others => 0.0]; -- Accumulates adjustments to Diag
 
          for Row in 1 .. N - 1 loop
             for Col in Row + 1 .. N loop
index a3e0e32caab7210354ad87ef429583729eaa04b9..6e729edfd9aa96f3b039a757ef9b70c358b0cca0 100644 (file)
@@ -90,10 +90,10 @@ package body Ada.Strings.Text_Buffers.Bounded is
             --  If this aggregate becomes illegal due to new field, don't
             --  forget to add corresponding assignment statement below.
             Dummy : array (1 .. 0) of Buffer_Type (0) :=
-              (others =>
-                 (Max_Characters => 0, Chars => <>, Indentation => <>,
+              [others =>
+                 [Max_Characters => 0, Chars => <>, Indentation => <>,
                   Indent_Pending => <>, UTF_8_Length => <>, UTF_8_Column => <>,
-                  All_7_Bits     => <>, All_8_Bits => <>, Truncated => <>));
+                  All_7_Bits     => <>, All_8_Bits => <>, Truncated => <>]];
          begin
             Buffer.Indentation    := Defaulted.Indentation;
             Buffer.Indent_Pending := Defaulted.Indent_Pending;
index 8ac55128e35bddb3cbc1013bb726e97a06f48dc4..7cf7a343acae94f0877872c81e914407dfb621a3 100644 (file)
@@ -42,7 +42,7 @@ package body Ada.Strings.Text_Buffers.Formatting is
       X1, X2, X3, X4, X5, X6, X7, X8, X9 : Utils.UTF_8_Lines := "")
    is
       J : Positive := T'First;
-      Used : array (1 .. 9) of Boolean := (others => False);
+      Used : array (1 .. 9) of Boolean := [others => False];
    begin
       while J <= T'Last loop
          if T (J) = '\' then
index 9ae3d28c6cb1591a5bf1184713c96e1762e63497..b97ec02c1e1c9a82e509da351857a61b4a6eab35 100644 (file)
@@ -103,10 +103,10 @@ package body Ada.Strings.Text_Buffers.Unbounded is
             --  If this aggregate becomes illegal due to new field, don't
             --  forget to add corresponding assignment statement below.
             Dummy : array (1 .. 0) of Buffer_Type :=
-              (others =>
-                 (Indentation  => <>, Indent_Pending => <>, UTF_8_Length => <>,
+              [others =>
+                 [Indentation  => <>, Indent_Pending => <>, UTF_8_Length => <>,
                   UTF_8_Column => <>, All_7_Bits => <>, All_8_Bits => <>,
-                  List         => <>, Last_Used => <>));
+                  List         => <>, Last_Used => <>]];
          begin
             Buffer.Indentation    := Defaulted.Indentation;
             Buffer.Indent_Pending := Defaulted.Indent_Pending;
index b32b2d38d7511093408bbce3dd48847c3a341bb3..2d7d371b95e7036d14ee3bb90a244b7b529d723f 100644 (file)
@@ -35,28 +35,28 @@ package body Ada.Strings.Text_Buffers.Utils is
      (Buffer : in out Root_Buffer_Type'Class; Item : Character_7)
    is
    begin
-      Put (Buffer, (1 => Item));
+      Put (Buffer, [Item]);
    end Put_7bit;
 
    procedure Put_Character
      (Buffer : in out Root_Buffer_Type'Class; Item : Character)
    is
    begin
-      Put (Buffer, (1 => Item));
+      Put (Buffer, [Item]);
    end Put_Character;
 
    procedure Put_Wide_Character
      (Buffer : in out Root_Buffer_Type'Class; Item : Wide_Character)
    is
    begin
-      Wide_Put (Buffer, (1 => Item));
+      Wide_Put (Buffer, [Item]);
    end Put_Wide_Character;
 
    procedure Put_Wide_Wide_Character
      (Buffer : in out Root_Buffer_Type'Class; Item : Wide_Wide_Character)
    is
    begin
-      Wide_Wide_Put (Buffer, (1 => Item));
+      Wide_Wide_Put (Buffer, [Item]);
    end Put_Wide_Wide_Character;
 
    procedure Put_UTF_8_Lines
index 4d280ec232def91634985b9877499e8ab2be14a2..8d2f6f7d41191db6a2406e04199c2e4042687319 100644 (file)
@@ -64,37 +64,37 @@ private
    package L renames Ada.Characters.Latin_1;
 
    Control_Set               : constant Character_Set :=
-     (L.NUL                  ..  L.US                  => True,
+     [L.NUL                  ..  L.US                  => True,
       L.DEL                  ..  L.APC                 => True,
-      others                                           => False);
+      others                                           => False];
 
    Graphic_Set               : constant Character_Set :=
-     (L.Space                ..  L.Tilde               => True,
+     [L.Space                ..  L.Tilde               => True,
       L.No_Break_Space       ..  L.LC_Y_Diaeresis      => True,
-      others                                           => False);
+      others                                           => False];
 
    Letter_Set                : constant Character_Set :=
-     ('A'                    .. 'Z'                    => True,
+     ['A'                    .. 'Z'                    => True,
       L.LC_A                 ..  L.LC_Z                => True,
       L.UC_A_Grave           ..  L.UC_O_Diaeresis      => True,
       L.UC_O_Oblique_Stroke  ..  L.LC_O_Diaeresis      => True,
       L.LC_O_Oblique_Stroke  ..  L.LC_Y_Diaeresis      => True,
-      others                                           => False);
+      others                                           => False];
 
    Lower_Set                 : constant Character_Set :=
-     (L.LC_A                 ..  L.LC_Z                => True,
+     [L.LC_A                 ..  L.LC_Z                => True,
       L.LC_German_Sharp_S    ..  L.LC_O_Diaeresis      => True,
       L.LC_O_Oblique_Stroke  ..  L.LC_Y_Diaeresis      => True,
-      others                                           => False);
+      others                                           => False];
 
    Upper_Set                 : constant Character_Set :=
-     ('A'                    ..  'Z'                   => True,
+     ['A'                    ..  'Z'                   => True,
       L.UC_A_Grave           ..  L.UC_O_Diaeresis      => True,
       L.UC_O_Oblique_Stroke  ..  L.UC_Icelandic_Thorn  => True,
-      others                                           => False);
+      others                                           => False];
 
    Basic_Set                 : constant Character_Set :=
-     ('A'                    .. 'Z'                    => True,
+     ['A'                    .. 'Z'                    => True,
       L.LC_A                 ..  L.LC_Z                => True,
       L.UC_AE_Diphthong      ..  L.UC_AE_Diphthong     => True,
       L.LC_AE_Diphthong      ..  L.LC_AE_Diphthong     => True,
@@ -103,40 +103,40 @@ private
       L.LC_Icelandic_Thorn   ..  L.LC_Icelandic_Thorn  => True,
       L.UC_Icelandic_Eth     ..  L.UC_Icelandic_Eth    => True,
       L.LC_Icelandic_Eth     ..  L.LC_Icelandic_Eth    => True,
-      others                                           => False);
+      others                                           => False];
 
    Decimal_Digit_Set         : constant Character_Set :=
-     ('0'                    ..  '9'                   => True,
-      others                                           => False);
+     ['0'                    ..  '9'                   => True,
+      others                                           => False];
 
    Hexadecimal_Digit_Set     : constant Character_Set :=
-     ('0'                    ..  '9'                   => True,
+     ['0'                    ..  '9'                   => True,
       'A'                    ..  'F'                   => True,
       L.LC_A                 ..  L.LC_F                => True,
-      others                                           => False);
+      others                                           => False];
 
    Alphanumeric_Set          : constant Character_Set :=
-     ('0'                    ..  '9'                   => True,
+     ['0'                    ..  '9'                   => True,
       'A'                    ..  'Z'                   => True,
       L.LC_A                 ..  L.LC_Z                => True,
       L.UC_A_Grave           ..  L.UC_O_Diaeresis      => True,
       L.UC_O_Oblique_Stroke  ..  L.LC_O_Diaeresis      => True,
       L.LC_O_Oblique_Stroke  ..  L.LC_Y_Diaeresis      => True,
-      others                                           => False);
+      others                                           => False];
 
    Special_Set               : constant Character_Set :=
-     (L.Space                ..  L.Solidus             => True,
+     [L.Space                ..  L.Solidus             => True,
       L.Colon                ..  L.Commercial_At       => True,
       L.Left_Square_Bracket  ..  L.Grave               => True,
       L.Left_Curly_Bracket   ..  L.Tilde               => True,
       L.No_Break_Space       ..  L.Inverted_Question   => True,
       L.Multiplication_Sign  ..  L.Multiplication_Sign => True,
       L.Division_Sign        ..  L.Division_Sign       => True,
-      others                                           => False);
+      others                                           => False];
 
    ISO_646_Set               : constant Character_Set :=
-     (L.NUL                  ..  L.DEL                 => True,
-      others                                           => False);
+     [L.NUL                  ..  L.DEL                 => True,
+      others                                           => False];
 
    Lower_Case_Map : constant Character_Mapping :=
      (L.NUL                         &  -- NUL                             0
index e8201843f7a826e91af2164d620a5a891d20a94d..6efdebc18c971f18b10c8793269d15442743af9a 100644 (file)
@@ -2202,7 +2202,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
                  Slice (Head'Result, 1, Length (Source)) = To_String (Source)
                and then
                  Slice (Head'Result, Length (Source) + 1, Count) =
-                   (1 .. Count - Length (Source) => Pad),
+                   [1 .. Count - Length (Source) => Pad],
 
            Count > Max_Length and then Drop = Right
            =>
@@ -2213,13 +2213,13 @@ package Ada.Strings.Bounded with SPARK_Mode is
                  Slice (Head'Result, 1, Length (Source)) = To_String (Source)
                and then
                  Slice (Head'Result, Length (Source) + 1, Max_Length) =
-                   (1 .. Max_Length - Length (Source) => Pad),
+                   [1 .. Max_Length - Length (Source) => Pad],
 
            Count - Length (Source) > Max_Length and then Drop = Left
            =>
              --  Source is fully dropped at the left
 
-             To_String (Head'Result) = (1 .. Max_Length => Pad),
+             To_String (Head'Result) = [1 .. Max_Length => Pad],
 
            others
            =>
@@ -2232,7 +2232,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
                and then
                  Slice (Head'Result,
                    Max_Length - Count + Length (Source) + 1, Max_Length) =
-                     (1 .. Count - Length (Source) => Pad));
+                     [1 .. Count - Length (Source) => Pad]);
 
       procedure Head
         (Source : in out Bounded_String;
@@ -2258,7 +2258,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
                    To_String (Source'Old)
                and then
                  Slice (Source, Length (Source'Old) + 1, Count) =
-                   (1 .. Count - Length (Source'Old) => Pad),
+                   [1 .. Count - Length (Source'Old) => Pad],
 
            Count > Max_Length and then Drop = Right
            =>
@@ -2270,13 +2270,13 @@ package Ada.Strings.Bounded with SPARK_Mode is
                    To_String (Source'Old)
                and then
                  Slice (Source, Length (Source'Old) + 1, Max_Length) =
-                   (1 .. Max_Length - Length (Source'Old) => Pad),
+                   [1 .. Max_Length - Length (Source'Old) => Pad],
 
            Count - Length (Source) > Max_Length and then Drop = Left
            =>
              --  Source is fully dropped on the left
 
-             To_String (Source) = (1 .. Max_Length => Pad),
+             To_String (Source) = [1 .. Max_Length => Pad],
 
            others
            =>
@@ -2290,7 +2290,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
                and then
                  Slice (Source,
                    Max_Length - Count + Length (Source'Old) + 1, Max_Length) =
-                     (1 .. Count - Length (Source'Old) => Pad));
+                     [1 .. Count - Length (Source'Old) => Pad]);
 
       function Tail
         (Source : Bounded_String;
@@ -2316,7 +2316,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
              Length (Tail'Result) = Count
                and then
                  Slice (Tail'Result, 1, Count - Length (Source)) =
-                   (1 .. Count - Length (Source) => Pad)
+                   [1 .. Count - Length (Source) => Pad]
                and then
                  Slice (Tail'Result, Count - Length (Source) + 1, Count) =
                    To_String (Source),
@@ -2328,7 +2328,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
              Length (Tail'Result) = Max_Length
                and then
                  Slice (Tail'Result, 1, Max_Length - Length (Source)) =
-                   (1 .. Max_Length - Length (Source) => Pad)
+                   [1 .. Max_Length - Length (Source) => Pad]
                and then
                  (if Length (Source) > 0 then
                     Slice (Tail'Result,
@@ -2339,7 +2339,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
            =>
              --  Source is fully dropped on the right
 
-             To_String (Tail'Result) = (1 .. Max_Length => Pad),
+             To_String (Tail'Result) = [1 .. Max_Length => Pad],
 
            others
            =>
@@ -2348,7 +2348,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
              Length (Tail'Result) = Max_Length
                and then
                  Slice (Tail'Result, 1, Count - Length (Source)) =
-                   (1 .. Count - Length (Source) => Pad)
+                   [1 .. Count - Length (Source) => Pad]
                and then
                  Slice (Tail'Result, Count - Length (Source) + 1, Max_Length) =
                    Slice (Source, 1, Max_Length - Count + Length (Source)));
@@ -2378,7 +2378,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
              Length (Source) = Count
                and then
                  Slice (Source, 1, Count - Length (Source'Old)) =
-                   (1 .. Count - Length (Source'Old) => Pad)
+                   [1 .. Count - Length (Source'Old) => Pad]
                and then
                  Slice (Source, Count - Length (Source'Old) + 1, Count) =
                    To_String (Source'Old),
@@ -2390,7 +2390,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
              Length (Source) = Max_Length
                and then
                  Slice (Source, 1, Max_Length - Length (Source'Old)) =
-                   (1 .. Max_Length - Length (Source'Old) => Pad)
+                   [1 .. Max_Length - Length (Source'Old) => Pad]
                and then
                  (if Length (Source'Old) > 0 then
                     Slice (Source,
@@ -2401,7 +2401,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
            =>
              --  Source is fully dropped at the right
 
-             To_String (Source) = (1 .. Max_Length => Pad),
+             To_String (Source) = [1 .. Max_Length => Pad],
 
            others
            =>
@@ -2410,7 +2410,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
              Length (Source) = Max_Length
                and then
                  Slice (Source, 1, Count - Length (Source'Old)) =
-                   (1 .. Count - Length (Source'Old) => Pad)
+                   [1 .. Count - Length (Source'Old) => Pad]
                and then
                  Slice (Source, Count - Length (Source'Old) + 1, Max_Length) =
                    Slice (Source'Old,
@@ -2425,7 +2425,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
          Right : Character) return Bounded_String
       with
         Pre  => Left <= Max_Length,
-        Post => To_String ("*"'Result) = (1 .. Left => Right);
+        Post => To_String ("*"'Result) = [1 .. Left => Right];
 
       function "*"
         (Left  : Natural;
@@ -2461,7 +2461,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
         Pre  => (if Count > Max_Length then Drop /= Error),
         Post =>
           To_String (Replicate'Result) =
-            (1 .. Natural'Min (Max_Length, Count) => Item);
+            [1 .. Natural'Min (Max_Length, Count) => Item];
 
       function Replicate
         (Count : Natural;
@@ -2565,7 +2565,7 @@ package Ada.Strings.Bounded with SPARK_Mode is
                               (Max_Length     => Max_Length,
                                Current_Length => 0,
                                Data           =>
-                                 (1 .. Max_Length => ASCII.NUL));
+                                 [1 .. Max_Length => ASCII.NUL]);
 
       pragma Inline (To_Bounded_String);
 
index 1d9fd1b53030c2193569fcddc2a0c065e3525ac5..0d6c5d076633a3fd8b4164342460826089137f87 100644 (file)
@@ -1258,7 +1258,7 @@ package Ada.Strings.Fixed with SPARK_Mode is
           Head'Result (1 .. Source'Length) = Source
             and then
               Head'Result (Source'Length + 1 .. Count)
-              = (1 .. Count - Source'Length => Pad)),
+              = [1 .. Count - Source'Length => Pad]),
      Global         => null;
    --  Returns a string of length Count. If Count <= Source'Length, the string
    --  comprises the first Count characters of Source. Otherwise, its contents
@@ -1315,10 +1315,10 @@ package Ada.Strings.Fixed with SPARK_Mode is
            --  characters.
 
           (if Source'Length = 0
-           then Tail'Result = (1 .. Count => Pad)
+           then Tail'Result = [1 .. Count => Pad]
            else
              Tail'Result (1 .. Count - Source'Length)
-             = (1 .. Count - Source'Length => Pad)
+             = [1 .. Count - Source'Length => Pad]
                and then
                  Tail'Result (Count - Source'Length + 1 .. Tail'Result'Last)
                  = Source)),
index c87f4e52d7442fd81356ac0505bb8866902b3aa7..d6b05d2277ce64f9368326a86388a1df5d9b4408 100644 (file)
@@ -135,7 +135,7 @@ is
       J      : Natural;
 
       type Character_Index is array (Character) of Natural with Ghost;
-      Indexes : Character_Index := (others => 0) with Ghost;
+      Indexes : Character_Index := [others => 0] with Ghost;
 
    begin
       J := 0;
@@ -367,7 +367,7 @@ is
 
       Domain : String (1 .. Map'Length) with Ghost, Relaxed_Initialization;
       type Character_Index is array (Character) of Natural with Ghost;
-      Indexes : Character_Index := (others => 0) with Ghost;
+      Indexes : Character_Index := [others => 0] with Ghost;
 
    --  Start of processing for To_Range
 
index 1a15d5dc2d6e76c996fe8a3344349b13282df400..320564e71c10ae6d6550dd94c801f0513cbd5caa 100644 (file)
@@ -376,7 +376,7 @@ private
    --  the defined operations in the spec, but the operations defined
    --  on Character_Set_Internal remain visible.
 
-   Null_Set : constant Character_Set := (others => False);
+   Null_Set : constant Character_Set := [others => False];
 
    type Character_Mapping is array (Character) of Character;
 
index a94d6cad4e02899b997dcbfe3cf120187002bb36..b9d36698f7f27b866fb78205511ab6facdb4ef25 100644 (file)
@@ -844,7 +844,7 @@ package body Ada.Strings.Superbounded with SPARK_Mode is
 
       elsif Count <= Max_Length then
          Result.Data (1 .. Slen) := Source.Data (1 .. Slen);
-         Result.Data (Slen + 1 .. Count) := (others => Pad);
+         Result.Data (Slen + 1 .. Count) := [others => Pad];
          Result.Current_Length := Count;
 
       else
@@ -853,18 +853,18 @@ package body Ada.Strings.Superbounded with SPARK_Mode is
                Result.Data (1 .. Slen) := Source.Data (1 .. Slen);
 
                if Slen < Max_Length then
-                  Result.Data (Slen + 1 .. Max_Length) := (others => Pad);
+                  Result.Data (Slen + 1 .. Max_Length) := [others => Pad];
                end if;
 
             when Strings.Left =>
                if Npad >= Max_Length then
-                  Result.Data := (others => Pad);
+                  Result.Data := [others => Pad];
 
                else
                   Result.Data (1 .. Max_Length - Npad) :=
                     Source.Data (Count - Max_Length + 1 .. Slen);
                   Result.Data (Max_Length - Npad + 1 .. Max_Length) :=
-                    (others => Pad);
+                    [others => Pad];
                end if;
 
             when Strings.Error =>
@@ -893,26 +893,26 @@ package body Ada.Strings.Superbounded with SPARK_Mode is
          Source.Current_Length := Count;
 
       elsif Count <= Max_Length then
-         Source.Data (Slen + 1 .. Count) := (others => Pad);
+         Source.Data (Slen + 1 .. Count) := [others => Pad];
          Source.Current_Length := Count;
 
       else
          case Drop is
             when Strings.Right =>
                if Slen < Max_Length then
-                  Source.Data (Slen + 1 .. Max_Length) := (others => Pad);
+                  Source.Data (Slen + 1 .. Max_Length) := [others => Pad];
                end if;
 
             when Strings.Left =>
                if Npad > Max_Length then
-                  Source.Data := (others => Pad);
+                  Source.Data := [others => Pad];
 
                else
                   Temp := Source.Data;
                   Source.Data (1 .. Max_Length - Npad) :=
                     Temp (Count - Max_Length + 1 .. Slen);
                   Source.Data (Max_Length - Npad + 1 .. Max_Length) :=
-                    (others => Pad);
+                    [others => Pad];
                end if;
 
             when Strings.Error =>
@@ -1385,14 +1385,14 @@ package body Ada.Strings.Superbounded with SPARK_Mode is
 
    begin
       if Count <= Max_Length then
-         Result.Data (1 .. Count) := (others => Item);
+         Result.Data (1 .. Count) := [others => Item];
          Result.Current_Length := Count;
 
       elsif Drop = Strings.Error then
          raise Ada.Strings.Length_Error;
 
       else
-         Result.Data (1 .. Max_Length) := (others => Item);
+         Result.Data (1 .. Max_Length) := [others => Item];
          Result.Current_Length := Max_Length;
       end if;
 
@@ -1686,7 +1686,7 @@ package body Ada.Strings.Superbounded with SPARK_Mode is
          end if;
 
       elsif Count <= Max_Length then
-         Result.Data (1 .. Npad) := (others => Pad);
+         Result.Data (1 .. Npad) := [others => Pad];
 
          if Slen > 0 then
             Result.Data (Npad + 1 .. Count) := Source.Data (1 .. Slen);
@@ -1698,16 +1698,16 @@ package body Ada.Strings.Superbounded with SPARK_Mode is
          case Drop is
             when Strings.Right =>
                if Npad >= Max_Length then
-                  Result.Data := (others => Pad);
+                  Result.Data := [others => Pad];
 
                else
-                  Result.Data (1 .. Npad) := (others => Pad);
+                  Result.Data (1 .. Npad) := [others => Pad];
                   Result.Data (Npad + 1 .. Max_Length) :=
                     Source.Data (1 .. Max_Length - Npad);
                end if;
 
             when Strings.Left =>
-               Result.Data (1 .. Max_Length - Slen) := (others => Pad);
+               Result.Data (1 .. Max_Length - Slen) := [others => Pad];
                Result.Data (Max_Length - Slen + 1 .. Max_Length) :=
                  Source.Data (1 .. Slen);
 
@@ -1743,7 +1743,7 @@ package body Ada.Strings.Superbounded with SPARK_Mode is
          end if;
 
       elsif Count <= Max_Length then
-         Source.Data (1 .. Npad) := (others => Pad);
+         Source.Data (1 .. Npad) := [others => Pad];
 
          if Slen > 0 then
             Source.Data (Npad + 1 .. Count) := Temp (1 .. Slen);
@@ -1755,16 +1755,16 @@ package body Ada.Strings.Superbounded with SPARK_Mode is
          case Drop is
             when Strings.Right =>
                if Npad >= Max_Length then
-                  Source.Data := (others => Pad);
+                  Source.Data := [others => Pad];
 
                else
-                  Source.Data (1 .. Npad) := (others => Pad);
+                  Source.Data (1 .. Npad) := [others => Pad];
                   Source.Data (Npad + 1 .. Max_Length) :=
                     Temp (1 .. Max_Length - Npad);
                end if;
 
             when Strings.Left =>
-               Source.Data (1 .. Max_Length - Slen) := (others => Pad);
+               Source.Data (1 .. Max_Length - Slen) := [others => Pad];
                Source.Data (Max_Length - Slen + 1 .. Max_Length) :=
                  Temp (1 .. Slen);
 
index ae4339f2957b27924a75edb3ec01e227e67c6116..5e582c7ae607be0d1b65e0d4d8067d06d69f5f1c 100644 (file)
@@ -2322,7 +2322,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
             and then
               String'(Super_Slice (Super_Head'Result,
                 Super_Length (Source) + 1, Count)) =
-                  (1 .. Count - Super_Length (Source) => Pad),
+                  [1 .. Count - Super_Length (Source) => Pad],
         Count > Source.Max_Length and then Drop = Right
         =>
           --  Source is followed by Pad characters
@@ -2334,13 +2334,13 @@ package Ada.Strings.Superbounded with SPARK_Mode is
             and then
               String'(Super_Slice (Super_Head'Result,
                 Super_Length (Source) + 1, Source.Max_Length)) =
-                  (1 .. Source.Max_Length - Super_Length (Source) => Pad),
+                  [1 .. Source.Max_Length - Super_Length (Source) => Pad],
         Count - Super_Length (Source) > Source.Max_Length and then Drop = Left
         =>
           --  Source is fully dropped on the left
 
           Super_To_String (Super_Head'Result) =
-            (1 .. Source.Max_Length => Pad),
+            [1 .. Source.Max_Length => Pad],
         others
         =>
           --  Source is partly dropped on the left
@@ -2355,7 +2355,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
               String'(Super_Slice (Super_Head'Result,
                 Source.Max_Length - Count + Super_Length (Source) + 1,
                 Source.Max_Length)) =
-                  (1 .. Count - Super_Length (Source) => Pad)),
+                  [1 .. Count - Super_Length (Source) => Pad]),
      Global         => null;
 
    procedure Super_Head
@@ -2382,7 +2382,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
             and then
               String'(Super_Slice (Source,
                 Super_Length (Source'Old) + 1, Count)) =
-                  (1 .. Count - Super_Length (Source'Old) => Pad),
+                  [1 .. Count - Super_Length (Source'Old) => Pad],
         Count > Source.Max_Length and then Drop = Right
         =>
           --  Source is followed by Pad characters
@@ -2394,12 +2394,12 @@ package Ada.Strings.Superbounded with SPARK_Mode is
             and then
               String'(Super_Slice (Source,
                 Super_Length (Source'Old) + 1, Source.Max_Length)) =
-                  (1 .. Source.Max_Length - Super_Length (Source'Old) => Pad),
+                  [1 .. Source.Max_Length - Super_Length (Source'Old) => Pad],
         Count - Super_Length (Source) > Source.Max_Length and then Drop = Left
         =>
           --  Source is fully dropped on the left
 
-          Super_To_String (Source) = (1 .. Source.Max_Length => Pad),
+          Super_To_String (Source) = [1 .. Source.Max_Length => Pad],
         others
         =>
           --  Source is partly dropped on the left
@@ -2414,7 +2414,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
               String'(Super_Slice (Source,
                 Source.Max_Length - Count + Super_Length (Source'Old) + 1,
                 Source.Max_Length)) =
-                  (1 .. Count - Super_Length (Source'Old) => Pad)),
+                  [1 .. Count - Super_Length (Source'Old) => Pad]),
      Global         => null;
 
    function Super_Tail
@@ -2443,7 +2443,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
             and then
               String'(Super_Slice (Super_Tail'Result,
                 1, Count - Super_Length (Source))) =
-                  (1 .. Count - Super_Length (Source) => Pad)
+                  [1 .. Count - Super_Length (Source) => Pad]
             and then
               Super_Slice (Super_Tail'Result,
                 Count - Super_Length (Source) + 1, Count) =
@@ -2456,7 +2456,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
             and then
               String'(Super_Slice (Super_Tail'Result,
                 1, Source.Max_Length - Super_Length (Source))) =
-                  (1 .. Source.Max_Length - Super_Length (Source) => Pad)
+                  [1 .. Source.Max_Length - Super_Length (Source) => Pad]
             and then
               (if Super_Length (Source) > 0 then
                  Super_Slice (Super_Tail'Result,
@@ -2469,7 +2469,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
           --  Source is fully dropped on the right
 
           Super_To_String (Super_Tail'Result) =
-            (1 .. Source.Max_Length => Pad),
+            [1 .. Source.Max_Length => Pad],
         others
         =>
           --  Source is partly dropped on the right
@@ -2478,7 +2478,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
             and then
               String'(Super_Slice (Super_Tail'Result,
                 1, Count - Super_Length (Source))) =
-                  (1 .. Count - Super_Length (Source) => Pad)
+                  [1 .. Count - Super_Length (Source) => Pad]
             and then
               String'(Super_Slice (Super_Tail'Result,
                 Count - Super_Length (Source) + 1, Source.Max_Length)) =
@@ -2512,7 +2512,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
             and then
               String'(Super_Slice (Source,
                 1, Count - Super_Length (Source'Old))) =
-                  (1 .. Count - Super_Length (Source'Old) => Pad)
+                  [1 .. Count - Super_Length (Source'Old) => Pad]
             and then
               Super_Slice (Source,
                 Count - Super_Length (Source'Old) + 1, Count) =
@@ -2525,7 +2525,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
             and then
               String'(Super_Slice (Source,
                 1, Source.Max_Length - Super_Length (Source'Old))) =
-                  (1 .. Source.Max_Length - Super_Length (Source'Old) => Pad)
+                  [1 .. Source.Max_Length - Super_Length (Source'Old) => Pad]
             and then
               (if Super_Length (Source'Old) > 0 then
                  Super_Slice (Source,
@@ -2537,7 +2537,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
         =>
           --  Source is fully dropped on the right
 
-          Super_To_String (Source) = (1 .. Source.Max_Length => Pad),
+          Super_To_String (Source) = [1 .. Source.Max_Length => Pad],
         others
         =>
           --  Source is partly dropped on the right
@@ -2546,7 +2546,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
             and then
               String'(Super_Slice (Source,
                 1, Count - Super_Length (Source'Old))) =
-                  (1 .. Count - Super_Length (Source'Old) => Pad)
+                  [1 .. Count - Super_Length (Source'Old) => Pad]
             and then
               String'(Super_Slice (Source,
                 Count - Super_Length (Source'Old) + 1, Source.Max_Length)) =
@@ -2569,7 +2569,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
    with
      Pre    => Left <= Max_Length,
      Post   => Times'Result.Max_Length = Max_Length
-       and then Super_To_String (Times'Result) = (1 .. Left => Right),
+       and then Super_To_String (Times'Result) = [1 .. Left => Right],
      Global => null;
    --  Note the additional parameter Max_Length
 
@@ -2613,7 +2613,7 @@ package Ada.Strings.Superbounded with SPARK_Mode is
      Pre    => (if Count > Max_Length then Drop /= Error),
      Post   => Super_Replicate'Result.Max_Length = Max_Length
        and then Super_To_String (Super_Replicate'Result) =
-         (1 .. Natural'Min (Max_Length, Count) => Item),
+         [1 .. Natural'Min (Max_Length, Count) => Item],
      Global => null;
    --  Note the additional parameter Max_Length
 
index bc0c6ce4355a6b640a0302f14e8b06bdd0fbfc52..f86a96921f24e73eb3c57cbd311f35a157340e6b 100644 (file)
@@ -94,7 +94,7 @@ package body Ada.Strings.Text_Buffers is
             Buffer.Indent_Pending := False;
             if Buffer.Indentation > 0 then
                Put_UTF_8_Implementation
-                 (Buffer, (1 .. Buffer.Indentation => ' '));
+                 (Buffer, [1 .. Buffer.Indentation => ' ']);
             end if;
          end if;
 
@@ -111,7 +111,7 @@ package body Ada.Strings.Text_Buffers is
       procedure New_Line (Buffer : in out Buffer_Type) is
       begin
          Buffer.Indent_Pending := False; --  just for a moment
-         Put (Buffer, (1 => ASCII.LF));
+         Put (Buffer, [ASCII.LF]);
          Buffer.Indent_Pending := True;
          Buffer.UTF_8_Column   := 1;
       end New_Line;
index fba30dfee8ab528875914dc454ec85708a970ee3..209c84aef3256254bf5f79287afccf5ecbfa2747 100644 (file)
@@ -94,7 +94,7 @@ package Ada.Strings.UTF_Encoding is
                 Character'Val (16#FE#);
 
    BOM_16   : constant UTF_16_Wide_String :=
-                (1 => Wide_Character'Val (16#FEFF#));
+                [Wide_Character'Val (16#FEFF#)];
 
    function Encoding
      (Item    : UTF_String;
index 9b3d0ad971b2e5935ff15e250359b695a412801e..1ddb83a3e4d21312a4afcb61f0748a7187cd2b90 100644 (file)
@@ -487,8 +487,8 @@ package Ada.Strings.Wide_Bounded is
                                    (Max_Length         => Max_Length,
                                     Current_Length     => 0,
                                     Data               =>
-                                      (1 .. Max_Length =>
-                                         Wide_Superbounded.Wide_NUL));
+                                      [1 .. Max_Length =>
+                                         Wide_Superbounded.Wide_NUL]);
 
       pragma Inline (To_Bounded_Wide_String);
 
index fba510a3860e984d206fe2868e65b358414cab19..6b5765f20ccff8d68347834743b81c981e64d401 100644 (file)
@@ -181,8 +181,7 @@ private
    overriding procedure Adjust     (Object : in out Wide_Character_Set);
    overriding procedure Finalize   (Object : in out Wide_Character_Set);
 
-   Null_Range : aliased constant Wide_Character_Ranges :=
-                  (1 .. 0 => (Low => ' ', High => ' '));
+   Null_Range : aliased constant Wide_Character_Ranges := [];
 
    Null_Set : constant Wide_Character_Set :=
                 (AF.Controlled with
index b81be14fd4c3844307b3c83de910451e5ef56045..302bf0f4b382aef4277941d227129ad444bc10ce 100644 (file)
@@ -852,7 +852,7 @@ package body Ada.Strings.Wide_Superbounded is
       elsif Count <= Max_Length then
          Result.Current_Length := Count;
          Result.Data (1 .. Slen) := Source.Data (1 .. Slen);
-         Result.Data (Slen + 1 .. Count) := (others => Pad);
+         Result.Data (Slen + 1 .. Count) := [others => Pad];
 
       else
          Result.Current_Length := Max_Length;
@@ -860,17 +860,17 @@ package body Ada.Strings.Wide_Superbounded is
          case Drop is
             when Strings.Right =>
                Result.Data (1 .. Slen) := Source.Data (1 .. Slen);
-               Result.Data (Slen + 1 .. Max_Length) := (others => Pad);
+               Result.Data (Slen + 1 .. Max_Length) := [others => Pad];
 
             when Strings.Left =>
                if Npad >= Max_Length then
-                  Result.Data := (others => Pad);
+                  Result.Data := [others => Pad];
 
                else
                   Result.Data (1 .. Max_Length - Npad) :=
                     Source.Data (Count - Max_Length + 1 .. Slen);
                   Result.Data (Max_Length - Npad + 1 .. Max_Length) :=
-                    (others => Pad);
+                    [others => Pad];
                end if;
 
             when Strings.Error =>
@@ -898,18 +898,18 @@ package body Ada.Strings.Wide_Superbounded is
 
       elsif Count <= Max_Length then
          Source.Current_Length := Count;
-         Source.Data (Slen + 1 .. Count) := (others => Pad);
+         Source.Data (Slen + 1 .. Count) := [others => Pad];
 
       else
          Source.Current_Length := Max_Length;
 
          case Drop is
             when Strings.Right =>
-               Source.Data (Slen + 1 .. Max_Length) := (others => Pad);
+               Source.Data (Slen + 1 .. Max_Length) := [others => Pad];
 
             when Strings.Left =>
                if Npad > Max_Length then
-                  Source.Data := (others => Pad);
+                  Source.Data := [others => Pad];
 
                else
                   Temp := Source.Data;
@@ -1386,7 +1386,7 @@ package body Ada.Strings.Wide_Superbounded is
          Result.Current_Length := Max_Length;
       end if;
 
-      Result.Data (1 .. Result.Current_Length) := (others => Item);
+      Result.Data (1 .. Result.Current_Length) := [others => Item];
       return Result;
    end Super_Replicate;
 
@@ -1542,7 +1542,7 @@ package body Ada.Strings.Wide_Superbounded is
 
       elsif Count <= Max_Length then
          Result.Current_Length := Count;
-         Result.Data (1 .. Npad) := (others => Pad);
+         Result.Data (1 .. Npad) := [others => Pad];
          Result.Data (Npad + 1 .. Count) := Source.Data (1 .. Slen);
 
       else
@@ -1551,16 +1551,16 @@ package body Ada.Strings.Wide_Superbounded is
          case Drop is
             when Strings.Right =>
                if Npad >= Max_Length then
-                  Result.Data := (others => Pad);
+                  Result.Data := [others => Pad];
 
                else
-                  Result.Data (1 .. Npad) := (others => Pad);
+                  Result.Data (1 .. Npad) := [others => Pad];
                   Result.Data (Npad + 1 .. Max_Length) :=
                     Source.Data (1 .. Max_Length - Npad);
                end if;
 
             when Strings.Left =>
-               Result.Data (1 .. Max_Length - Slen) := (others => Pad);
+               Result.Data (1 .. Max_Length - Slen) := [others => Pad];
                Result.Data (Max_Length - Slen + 1 .. Max_Length) :=
                  Source.Data (1 .. Slen);
 
@@ -1592,7 +1592,7 @@ package body Ada.Strings.Wide_Superbounded is
 
       elsif Count <= Max_Length then
          Source.Current_Length := Count;
-         Source.Data (1 .. Npad) := (others => Pad);
+         Source.Data (1 .. Npad) := [others => Pad];
          Source.Data (Npad + 1 .. Count) := Temp (1 .. Slen);
 
       else
@@ -1601,10 +1601,10 @@ package body Ada.Strings.Wide_Superbounded is
          case Drop is
             when Strings.Right =>
                if Npad >= Max_Length then
-                  Source.Data := (others => Pad);
+                  Source.Data := [others => Pad];
 
                else
-                  Source.Data (1 .. Npad) := (others => Pad);
+                  Source.Data (1 .. Npad) := [others => Pad];
                   Source.Data (Npad + 1 .. Max_Length) :=
                     Temp (1 .. Max_Length - Npad);
                end if;
@@ -1744,7 +1744,7 @@ package body Ada.Strings.Wide_Superbounded is
          end loop;
       end if;
 
-      Source.Data := (others => Wide_NUL);
+      Source.Data := [others => Wide_NUL];
       Source.Current_Length := Last - First + 1;
       Source.Data (1 .. Source.Current_Length) := Temp (First .. Last);
    end Super_Trim;
index d49d5773e7b1e39f4eb2a81796617edb4eff6b46..ae45e7c364a0ca5e5b56f7abe67aa96daec5779a 100644 (file)
@@ -493,11 +493,11 @@ package Ada.Strings.Wide_Wide_Bounded is
       --  the Wide_Wide_Superbounded package.
 
       Null_Bounded_Wide_Wide_String : constant Bounded_Wide_Wide_String :=
-                                   (Max_Length         => Max_Length,
+                                   [Max_Length         => Max_Length,
                                     Current_Length     => 0,
                                     Data               =>
-                                      (1 .. Max_Length =>
-                                        Wide_Wide_Superbounded.Wide_Wide_NUL));
+                                      [1 .. Max_Length =>
+                                        Wide_Wide_Superbounded.Wide_Wide_NUL]];
 
       pragma Inline (To_Bounded_Wide_Wide_String);
 
index 14650da64ae81e4b559b13285ae68748a73eb9e2..86ee971d3e456ba049d5b1d506e16126f675c354 100644 (file)
@@ -183,8 +183,7 @@ private
    procedure Adjust     (Object : in out Wide_Wide_Character_Set);
    procedure Finalize   (Object : in out Wide_Wide_Character_Set);
 
-   Null_Range : aliased constant Wide_Wide_Character_Ranges :=
-                  (1 .. 0 => (Low => ' ', High => ' '));
+   Null_Range : aliased constant Wide_Wide_Character_Ranges := [];
 
    Null_Set : constant Wide_Wide_Character_Set :=
                 (AF.Controlled with
index 92790a19ea197cf19e81e0006b747548d106d144..67997978c3c603e463880c20cd64d540d91d0d33 100644 (file)
@@ -853,7 +853,7 @@ package body Ada.Strings.Wide_Wide_Superbounded is
       elsif Count <= Max_Length then
          Result.Current_Length := Count;
          Result.Data (1 .. Slen) := Source.Data (1 .. Slen);
-         Result.Data (Slen + 1 .. Count) := (others => Pad);
+         Result.Data (Slen + 1 .. Count) := [others => Pad];
 
       else
          Result.Current_Length := Max_Length;
@@ -861,17 +861,17 @@ package body Ada.Strings.Wide_Wide_Superbounded is
          case Drop is
             when Strings.Right =>
                Result.Data (1 .. Slen) := Source.Data (1 .. Slen);
-               Result.Data (Slen + 1 .. Max_Length) := (others => Pad);
+               Result.Data (Slen + 1 .. Max_Length) := [others => Pad];
 
             when Strings.Left =>
                if Npad >= Max_Length then
-                  Result.Data := (others => Pad);
+                  Result.Data := [others => Pad];
 
                else
                   Result.Data (1 .. Max_Length - Npad) :=
                     Source.Data (Count - Max_Length + 1 .. Slen);
                   Result.Data (Max_Length - Npad + 1 .. Max_Length) :=
-                    (others => Pad);
+                    [others => Pad];
                end if;
 
             when Strings.Error =>
@@ -899,18 +899,18 @@ package body Ada.Strings.Wide_Wide_Superbounded is
 
       elsif Count <= Max_Length then
          Source.Current_Length := Count;
-         Source.Data (Slen + 1 .. Count) := (others => Pad);
+         Source.Data (Slen + 1 .. Count) := [others => Pad];
 
       else
          Source.Current_Length := Max_Length;
 
          case Drop is
             when Strings.Right =>
-               Source.Data (Slen + 1 .. Max_Length) := (others => Pad);
+               Source.Data (Slen + 1 .. Max_Length) := [others => Pad];
 
             when Strings.Left =>
                if Npad > Max_Length then
-                  Source.Data := (others => Pad);
+                  Source.Data := [others => Pad];
 
                else
                   Temp := Source.Data;
@@ -1389,7 +1389,7 @@ package body Ada.Strings.Wide_Wide_Superbounded is
          Result.Current_Length := Max_Length;
       end if;
 
-      Result.Data (1 .. Result.Current_Length) := (others => Item);
+      Result.Data (1 .. Result.Current_Length) := [others => Item];
       return Result;
    end Super_Replicate;
 
@@ -1546,7 +1546,7 @@ package body Ada.Strings.Wide_Wide_Superbounded is
 
       elsif Count <= Max_Length then
          Result.Current_Length := Count;
-         Result.Data (1 .. Npad) := (others => Pad);
+         Result.Data (1 .. Npad) := [others => Pad];
          Result.Data (Npad + 1 .. Count) := Source.Data (1 .. Slen);
 
       else
@@ -1555,16 +1555,16 @@ package body Ada.Strings.Wide_Wide_Superbounded is
          case Drop is
             when Strings.Right =>
                if Npad >= Max_Length then
-                  Result.Data := (others => Pad);
+                  Result.Data := [others => Pad];
 
                else
-                  Result.Data (1 .. Npad) := (others => Pad);
+                  Result.Data (1 .. Npad) := [others => Pad];
                   Result.Data (Npad + 1 .. Max_Length) :=
                     Source.Data (1 .. Max_Length - Npad);
                end if;
 
             when Strings.Left =>
-               Result.Data (1 .. Max_Length - Slen) := (others => Pad);
+               Result.Data (1 .. Max_Length - Slen) := [others => Pad];
                Result.Data (Max_Length - Slen + 1 .. Max_Length) :=
                  Source.Data (1 .. Slen);
 
@@ -1596,7 +1596,7 @@ package body Ada.Strings.Wide_Wide_Superbounded is
 
       elsif Count <= Max_Length then
          Source.Current_Length := Count;
-         Source.Data (1 .. Npad) := (others => Pad);
+         Source.Data (1 .. Npad) := [others => Pad];
          Source.Data (Npad + 1 .. Count) := Temp (1 .. Slen);
 
       else
@@ -1605,10 +1605,10 @@ package body Ada.Strings.Wide_Wide_Superbounded is
          case Drop is
             when Strings.Right =>
                if Npad >= Max_Length then
-                  Source.Data := (others => Pad);
+                  Source.Data := [others => Pad];
 
                else
-                  Source.Data (1 .. Npad) := (others => Pad);
+                  Source.Data (1 .. Npad) := [others => Pad];
                   Source.Data (Npad + 1 .. Max_Length) :=
                     Temp (1 .. Max_Length - Npad);
                end if;
@@ -1752,7 +1752,7 @@ package body Ada.Strings.Wide_Wide_Superbounded is
          end loop;
       end if;
 
-      Source.Data := (others => Wide_Wide_NUL);
+      Source.Data := [others => Wide_Wide_NUL];
       Source.Current_Length := Last - First + 1;
       Source.Data (1 .. Source.Current_Length) := Temp (First .. Last);
    end Super_Trim;
index 0f92502efaf39e24d59ccf293361366648badb6d..2e2ab4499dd80e227526ecde249672826d3b865c 100644 (file)
@@ -66,52 +66,52 @@ private
    subtype WC is Wide_Character;
 
    Control_Ranges           : aliased constant Wide_Character_Ranges :=
-     ((W.NUL, W.US),
-      (W.DEL, W.APC));
+     (W.NUL, W.US),
+       (W.DEL, W.APC)];
 
    Control_Set              : constant Wide_Character_Set :=
      (AF.Controlled with
       Control_Ranges'Unrestricted_Access);
 
    Graphic_Ranges           : aliased constant Wide_Character_Ranges :=
-     ((W.Space,       W.Tilde),
-      (WC'Val (256), WC'Last));
+     [ (W.Space,      W.Tilde),
+       (WC'Val (256), WC'Last)];
 
    Graphic_Set              : constant Wide_Character_Set :=
      (AF.Controlled with
       Graphic_Ranges'Unrestricted_Access);
 
    Letter_Ranges            : aliased constant Wide_Character_Ranges :=
-     (('A',                   'Z'),
-      (W.LC_A,                W.LC_Z),
-      (W.UC_A_Grave,          W.UC_O_Diaeresis),
-      (W.UC_O_Oblique_Stroke, W.LC_O_Diaeresis),
-      (W.LC_O_Oblique_Stroke, W.LC_Y_Diaeresis));
+     ('A',                   'Z'),
+       (W.LC_A,                W.LC_Z),
+       (W.UC_A_Grave,          W.UC_O_Diaeresis),
+       (W.UC_O_Oblique_Stroke, W.LC_O_Diaeresis),
+       (W.LC_O_Oblique_Stroke, W.LC_Y_Diaeresis)];
 
    Letter_Set               : constant Wide_Character_Set :=
      (AF.Controlled with
       Letter_Ranges'Unrestricted_Access);
 
    Lower_Ranges             : aliased constant Wide_Character_Ranges :=
-     (1 => (W.LC_A,                 W.LC_Z),
+     [1 => (W.LC_A,                 W.LC_Z),
       2 => (W.LC_German_Sharp_S,   W.LC_O_Diaeresis),
-      3 => (W.LC_O_Oblique_Stroke, W.LC_Y_Diaeresis));
+      3 => (W.LC_O_Oblique_Stroke, W.LC_Y_Diaeresis)];
 
    Lower_Set                : constant Wide_Character_Set :=
      (AF.Controlled with
       Lower_Ranges'Unrestricted_Access);
 
    Upper_Ranges             : aliased constant Wide_Character_Ranges :=
-     (1 => ('A',                   'Z'),
+     [1 => ('A',                   'Z'),
       2 => (W.UC_A_Grave,          W.UC_O_Diaeresis),
-      3 => (W.UC_O_Oblique_Stroke, W.UC_Icelandic_Thorn));
+      3 => (W.UC_O_Oblique_Stroke, W.UC_Icelandic_Thorn)];
 
    Upper_Set                : constant Wide_Character_Set :=
      (AF.Controlled with
       Upper_Ranges'Unrestricted_Access);
 
    Basic_Ranges             : aliased constant Wide_Character_Ranges :=
-     (1 => ('A',                   'Z'),
+     [1 => ('A',                   'Z'),
       2 => (W.LC_A,                W.LC_Z),
       3 => (W.UC_AE_Diphthong,     W.UC_AE_Diphthong),
       4 => (W.LC_AE_Diphthong,     W.LC_AE_Diphthong),
@@ -119,69 +119,69 @@ private
       6 => (W.UC_Icelandic_Thorn,  W.UC_Icelandic_Thorn),
       7 => (W.LC_Icelandic_Thorn,  W.LC_Icelandic_Thorn),
       8 => (W.UC_Icelandic_Eth,    W.UC_Icelandic_Eth),
-      9 => (W.LC_Icelandic_Eth,    W.LC_Icelandic_Eth));
+      9 => (W.LC_Icelandic_Eth,    W.LC_Icelandic_Eth)];
 
    Basic_Set                : constant Wide_Character_Set :=
      (AF.Controlled with
       Basic_Ranges'Unrestricted_Access);
 
    Decimal_Digit_Ranges     : aliased constant Wide_Character_Ranges :=
-     (1 => ('0', '9'));
+     [ ('0', '9')];
 
    Decimal_Digit_Set        : constant Wide_Character_Set :=
      (AF.Controlled with
       Decimal_Digit_Ranges'Unrestricted_Access);
 
    Hexadecimal_Digit_Ranges : aliased constant Wide_Character_Ranges :=
-     (1 => ('0', '9'),
+     [1 => ('0', '9'),
       2 => ('A', 'F'),
-      3 => (W.LC_A, W.LC_F));
+      3 => (W.LC_A, W.LC_F)];
 
    Hexadecimal_Digit_Set    : constant Wide_Character_Set :=
      (AF.Controlled with
       Hexadecimal_Digit_Ranges'Unrestricted_Access);
 
    Alphanumeric_Ranges      : aliased constant Wide_Character_Ranges :=
-     (1 => ('0',                   '9'),
+     [1 => ('0',                   '9'),
       2 => ('A',                   'Z'),
       3 => (W.LC_A,                W.LC_Z),
       4 => (W.UC_A_Grave,          W.UC_O_Diaeresis),
       5 => (W.UC_O_Oblique_Stroke, W.LC_O_Diaeresis),
-      6 => (W.LC_O_Oblique_Stroke, W.LC_Y_Diaeresis));
+      6 => (W.LC_O_Oblique_Stroke, W.LC_Y_Diaeresis)];
 
    Alphanumeric_Set         : constant Wide_Character_Set :=
      (AF.Controlled with
       Alphanumeric_Ranges'Unrestricted_Access);
 
    Special_Graphic_Ranges   : aliased constant Wide_Character_Ranges :=
-     (1 => (Wide_Space,            W.Solidus),
+     [1 => (Wide_Space,            W.Solidus),
       2 => (W.Colon,               W.Commercial_At),
       3 => (W.Left_Square_Bracket, W.Grave),
       4 => (W.Left_Curly_Bracket,  W.Tilde),
       5 => (W.No_Break_Space,      W.Inverted_Question),
       6 => (W.Multiplication_Sign, W.Multiplication_Sign),
-      7 => (W.Division_Sign,       W.Division_Sign));
+      7 => (W.Division_Sign,       W.Division_Sign)];
 
    Special_Graphic_Set      : constant Wide_Character_Set :=
      (AF.Controlled with
       Special_Graphic_Ranges'Unrestricted_Access);
 
    ISO_646_Ranges           : aliased constant Wide_Character_Ranges :=
-     (1 => (W.NUL, W.DEL));
+     [ (W.NUL, W.DEL)];
 
    ISO_646_Set              : constant Wide_Character_Set :=
      (AF.Controlled with
       ISO_646_Ranges'Unrestricted_Access);
 
    Character_Ranges         : aliased constant Wide_Character_Ranges :=
-     (1 => (W.NUL, WC'Val (255)));
+     [ (W.NUL, WC'Val (255))];
 
    Character_Set            : constant Wide_Character_Set :=
      (AF.Controlled with
       Character_Ranges'Unrestricted_Access);
 
    Lower_Case_Mapping : aliased constant Wide_Character_Mapping_Values :=
-     (Length => 56,
+     [Length => 56,
 
       Domain =>
         "ABCDEFGHIJKLMNOPQRSTUVWXYZ" &
@@ -247,14 +247,14 @@ private
          W.LC_U_Circumflex           &
          W.LC_U_Diaeresis            &
          W.LC_Y_Acute                &
-         W.LC_Icelandic_Thorn);
+         W.LC_Icelandic_Thorn];
 
    Lower_Case_Map : constant Wide_Character_Mapping :=
      (AF.Controlled with
       Map => Lower_Case_Mapping'Unrestricted_Access);
 
    Upper_Case_Mapping : aliased constant Wide_Character_Mapping_Values :=
-     (Length => 56,
+     [Length => 56,
 
       Domain =>
         "abcdefghijklmnopqrstuvwxyz" &
@@ -320,14 +320,14 @@ private
          W.UC_U_Circumflex           &
          W.UC_U_Diaeresis            &
          W.UC_Y_Acute                &
-         W.UC_Icelandic_Thorn);
+         W.UC_Icelandic_Thorn];
 
    Upper_Case_Map : constant Wide_Character_Mapping :=
      (AF.Controlled with
       Upper_Case_Mapping'Unrestricted_Access);
 
    Basic_Mapping : aliased constant Wide_Character_Mapping_Values :=
-     (Length => 55,
+     [Length => 55,
 
       Domain =>
         W.UC_A_Grave          &
@@ -441,7 +441,7 @@ private
         'u'        &  -- LC_U_Circumflex
         'u'        &  -- LC_U_Diaeresis
         'y'        &  -- LC_Y_Acute
-        'y');         -- LC_Y_Diaeresis
+        'y'];         -- LC_Y_Diaeresis
 
    Basic_Map : constant Wide_Character_Mapping :=
      (AF.Controlled with
index 82f0a6b8ce717c5a2d4e0f70e7f0a7ebb4a8366a..a5b8afc7d2424e9bb0d1d6db4a6c125a8a266aef 100644 (file)
@@ -66,52 +66,52 @@ private
    subtype WC is Wide_Wide_Character;
 
    Control_Ranges           : aliased constant Wide_Wide_Character_Ranges :=
-     ((W.NUL, W.US),
-      (W.DEL, W.APC));
+     (W.NUL, W.US),
+       (W.DEL, W.APC)];
 
    Control_Set              : constant Wide_Wide_Character_Set :=
      (AF.Controlled with
       Control_Ranges'Unrestricted_Access);
 
    Graphic_Ranges           : aliased constant Wide_Wide_Character_Ranges :=
-     ((W.Space,       W.Tilde),
-      (WC'Val (256), WC'Last));
+     [ (W.Space,      W.Tilde),
+       (WC'Val (256), WC'Last)];
 
    Graphic_Set              : constant Wide_Wide_Character_Set :=
      (AF.Controlled with
       Graphic_Ranges'Unrestricted_Access);
 
    Letter_Ranges            : aliased constant Wide_Wide_Character_Ranges :=
-     (('A',                   'Z'),
-      (W.LC_A,                W.LC_Z),
-      (W.UC_A_Grave,          W.UC_O_Diaeresis),
-      (W.UC_O_Oblique_Stroke, W.LC_O_Diaeresis),
-      (W.LC_O_Oblique_Stroke, W.LC_Y_Diaeresis));
+     [ ('A',                  'Z'),
+       (W.LC_A,                W.LC_Z),
+       (W.UC_A_Grave,          W.UC_O_Diaeresis),
+       (W.UC_O_Oblique_Stroke, W.LC_O_Diaeresis),
+       (W.LC_O_Oblique_Stroke, W.LC_Y_Diaeresis)];
 
    Letter_Set               : constant Wide_Wide_Character_Set :=
      (AF.Controlled with
       Letter_Ranges'Unrestricted_Access);
 
    Lower_Ranges             : aliased constant Wide_Wide_Character_Ranges :=
-     (1 => (W.LC_A,                 W.LC_Z),
+     [1 => (W.LC_A,                 W.LC_Z),
       2 => (W.LC_German_Sharp_S,   W.LC_O_Diaeresis),
-      3 => (W.LC_O_Oblique_Stroke, W.LC_Y_Diaeresis));
+      3 => (W.LC_O_Oblique_Stroke, W.LC_Y_Diaeresis)];
 
    Lower_Set                : constant Wide_Wide_Character_Set :=
      (AF.Controlled with
       Lower_Ranges'Unrestricted_Access);
 
    Upper_Ranges             : aliased constant Wide_Wide_Character_Ranges :=
-     (1 => ('A',                   'Z'),
+     [1 => ('A',                   'Z'),
       2 => (W.UC_A_Grave,          W.UC_O_Diaeresis),
-      3 => (W.UC_O_Oblique_Stroke, W.UC_Icelandic_Thorn));
+      3 => (W.UC_O_Oblique_Stroke, W.UC_Icelandic_Thorn)];
 
    Upper_Set                : constant Wide_Wide_Character_Set :=
      (AF.Controlled with
       Upper_Ranges'Unrestricted_Access);
 
    Basic_Ranges             : aliased constant Wide_Wide_Character_Ranges :=
-     (1 => ('A',                   'Z'),
+     [1 => ('A',                   'Z'),
       2 => (W.LC_A,                W.LC_Z),
       3 => (W.UC_AE_Diphthong,     W.UC_AE_Diphthong),
       4 => (W.LC_AE_Diphthong,     W.LC_AE_Diphthong),
@@ -119,69 +119,69 @@ private
       6 => (W.UC_Icelandic_Thorn,  W.UC_Icelandic_Thorn),
       7 => (W.LC_Icelandic_Thorn,  W.LC_Icelandic_Thorn),
       8 => (W.UC_Icelandic_Eth,    W.UC_Icelandic_Eth),
-      9 => (W.LC_Icelandic_Eth,    W.LC_Icelandic_Eth));
+      9 => (W.LC_Icelandic_Eth,    W.LC_Icelandic_Eth)];
 
    Basic_Set                : constant Wide_Wide_Character_Set :=
      (AF.Controlled with
       Basic_Ranges'Unrestricted_Access);
 
    Decimal_Digit_Ranges     : aliased constant Wide_Wide_Character_Ranges :=
-     (1 => ('0', '9'));
+     [ ('0', '9')];
 
    Decimal_Digit_Set        : constant Wide_Wide_Character_Set :=
      (AF.Controlled with
       Decimal_Digit_Ranges'Unrestricted_Access);
 
    Hexadecimal_Digit_Ranges : aliased constant Wide_Wide_Character_Ranges :=
-     (1 => ('0', '9'),
+     [1 => ('0', '9'),
       2 => ('A', 'F'),
-      3 => (W.LC_A, W.LC_F));
+      3 => (W.LC_A, W.LC_F)];
 
    Hexadecimal_Digit_Set    : constant Wide_Wide_Character_Set :=
      (AF.Controlled with
       Hexadecimal_Digit_Ranges'Unrestricted_Access);
 
    Alphanumeric_Ranges      : aliased constant Wide_Wide_Character_Ranges :=
-     (1 => ('0',                   '9'),
+     [1 => ('0',                   '9'),
       2 => ('A',                   'Z'),
       3 => (W.LC_A,                W.LC_Z),
       4 => (W.UC_A_Grave,          W.UC_O_Diaeresis),
       5 => (W.UC_O_Oblique_Stroke, W.LC_O_Diaeresis),
-      6 => (W.LC_O_Oblique_Stroke, W.LC_Y_Diaeresis));
+      6 => (W.LC_O_Oblique_Stroke, W.LC_Y_Diaeresis)];
 
    Alphanumeric_Set         : constant Wide_Wide_Character_Set :=
      (AF.Controlled with
       Alphanumeric_Ranges'Unrestricted_Access);
 
    Special_Graphic_Ranges   : aliased constant Wide_Wide_Character_Ranges :=
-     (1 => (Wide_Wide_Space,            W.Solidus),
+     [1 => (Wide_Wide_Space,            W.Solidus),
       2 => (W.Colon,               W.Commercial_At),
       3 => (W.Left_Square_Bracket, W.Grave),
       4 => (W.Left_Curly_Bracket,  W.Tilde),
       5 => (W.No_Break_Space,      W.Inverted_Question),
       6 => (W.Multiplication_Sign, W.Multiplication_Sign),
-      7 => (W.Division_Sign,       W.Division_Sign));
+      7 => (W.Division_Sign,       W.Division_Sign)];
 
    Special_Graphic_Set      : constant Wide_Wide_Character_Set :=
      (AF.Controlled with
       Special_Graphic_Ranges'Unrestricted_Access);
 
    ISO_646_Ranges           : aliased constant Wide_Wide_Character_Ranges :=
-     (1 => (W.NUL, W.DEL));
+     [ (W.NUL, W.DEL)];
 
    ISO_646_Set              : constant Wide_Wide_Character_Set :=
      (AF.Controlled with
       ISO_646_Ranges'Unrestricted_Access);
 
    Character_Ranges         : aliased constant Wide_Wide_Character_Ranges :=
-     (1 => (W.NUL, WC'Val (255)));
+     [ (W.NUL, WC'Val (255))];
 
    Character_Set            : constant Wide_Wide_Character_Set :=
      (AF.Controlled with
       Character_Ranges'Unrestricted_Access);
 
    Lower_Case_Mapping : aliased constant Wide_Wide_Character_Mapping_Values :=
-     (Length => 56,
+     [Length => 56,
 
       Domain =>
         "ABCDEFGHIJKLMNOPQRSTUVWXYZ" &
@@ -247,14 +247,14 @@ private
          W.LC_U_Circumflex           &
          W.LC_U_Diaeresis            &
          W.LC_Y_Acute                &
-         W.LC_Icelandic_Thorn);
+         W.LC_Icelandic_Thorn];
 
    Lower_Case_Map : constant Wide_Wide_Character_Mapping :=
      (AF.Controlled with
       Map => Lower_Case_Mapping'Unrestricted_Access);
 
    Upper_Case_Mapping : aliased constant Wide_Wide_Character_Mapping_Values :=
-     (Length => 56,
+     [Length => 56,
 
       Domain =>
         "abcdefghijklmnopqrstuvwxyz" &
@@ -320,14 +320,14 @@ private
          W.UC_U_Circumflex           &
          W.UC_U_Diaeresis            &
          W.UC_Y_Acute                &
-         W.UC_Icelandic_Thorn);
+         W.UC_Icelandic_Thorn];
 
    Upper_Case_Map : constant Wide_Wide_Character_Mapping :=
      (AF.Controlled with
       Upper_Case_Mapping'Unrestricted_Access);
 
    Basic_Mapping : aliased constant Wide_Wide_Character_Mapping_Values :=
-     (Length => 55,
+     [Length => 55,
 
       Domain =>
         W.UC_A_Grave          &
@@ -441,7 +441,7 @@ private
         'u'        &  -- LC_U_Circumflex
         'u'        &  -- LC_U_Diaeresis
         'y'        &  -- LC_Y_Acute
-        'y');         -- LC_Y_Diaeresis
+        'y'];         -- LC_Y_Diaeresis
 
    Basic_Map : constant Wide_Wide_Character_Mapping :=
      (AF.Controlled with
index 6f198e5b316fd93fdba8725afea66a8623a801a0..36c73b87819cd66b43172d701b97979bdf65af08 100644 (file)
@@ -279,13 +279,13 @@ package body Ada.Text_IO.Editing is
            or else Pic.Start_Currency < Pic.Radix_Position
          then
             Answer (Pic.Start_Currency .. Pic.End_Currency) :=
-                                                        (others => ' ');
+                                                        [others => ' '];
             Answer (Pic.End_Currency - Currency_Symbol'Length + 1 ..
                     Pic.End_Currency) := Currency_Symbol;
 
          else
             Answer (Pic.Start_Currency .. Pic.End_Currency) :=
-                                                        (others => ' ');
+                                                        [others => ' '];
             Answer (Pic.Start_Currency ..
                     Pic.Start_Currency + Currency_Symbol'Length - 1) :=
                                                         Currency_Symbol;
index 57ed1dda05758f94cc6c37bd59cb9be6042646f6..e4e7bb0640c3e3dc428c8e51824b3aa1250934fc 100644 (file)
@@ -450,13 +450,13 @@ package body Ada.Wide_Text_IO.Editing is
            or else Pic.Start_Currency < Pic.Radix_Position
          then
             Answer (Pic.Start_Currency .. Pic.End_Currency) :=
-                                                        (others => ' ');
+                                                        [others => ' '];
             Answer (Pic.End_Currency - Currency_Symbol'Length + 1 ..
                     Pic.End_Currency) := Currency_Symbol;
 
          else
             Answer (Pic.Start_Currency .. Pic.End_Currency) :=
-                                                        (others => ' ');
+                                                        [others => ' '];
             Answer (Pic.Start_Currency ..
                     Pic.Start_Currency + Currency_Symbol'Length - 1) :=
                                                         Currency_Symbol;
index b04462144350f843c095a7e087c35d5abba3adf5..41668de977a0c8eaba50419c5cc9cdd55305184d 100644 (file)
@@ -451,13 +451,13 @@ package body Ada.Wide_Wide_Text_IO.Editing is
            or else Pic.Start_Currency < Pic.Radix_Position
          then
             Answer (Pic.Start_Currency .. Pic.End_Currency) :=
-                                                        (others => ' ');
+                                                        [others => ' '];
             Answer (Pic.End_Currency - Currency_Symbol'Length + 1 ..
                     Pic.End_Currency) := Currency_Symbol;
 
          else
             Answer (Pic.Start_Currency .. Pic.End_Currency) :=
-                                                        (others => ' ');
+                                                        [others => ' '];
             Answer (Pic.Start_Currency ..
                     Pic.Start_Currency + Currency_Symbol'Length - 1) :=
                                                         Currency_Symbol;
index 6a8518b662e9133734831e65e08e23ab69293ba6..3c1f59abe636cc2f0dec32c1b4673876861f6788 100644 (file)
@@ -181,20 +181,20 @@ package body GNAT.Array_Split is
       then
          --  Whole string, or no separator used
 
-         return (Before => Array_End,
-                 After  => Array_End);
+         return [Before => Array_End,
+                 After  => Array_End];
 
       elsif Index = 1 then
-         return (Before => Array_End,
-                 After  => S.D.Source (S.D.Slices (Index).Stop + 1));
+         return [Before => Array_End,
+                 After  => S.D.Source (S.D.Slices (Index).Stop + 1)];
 
       elsif Index = S.D.N_Slice then
-         return (Before => S.D.Source (S.D.Slices (Index).Start - 1),
-                 After  => Array_End);
+         return [Before => S.D.Source (S.D.Slices (Index).Start - 1),
+                 After  => Array_End];
 
       else
-         return (Before => S.D.Source (S.D.Slices (Index).Start - 1),
-                 After  => S.D.Source (S.D.Slices (Index).Stop + 1));
+         return [Before => S.D.Source (S.D.Slices (Index).Start - 1),
+                 After  => S.D.Source (S.D.Slices (Index).Stop + 1)];
       end if;
    end Separators;
 
index 462e0d21fa92c7d9f74670676123ee7e04cf9936..1fdf1518bdd6df37ee7391ea4298da4b35890193 100644 (file)
@@ -627,8 +627,8 @@ package body GNAT.Calendar.Time_IO is
       subtype String3 is String (1 .. 3);
       Abbrev_Upper_Month_Names :
         constant array (Ada.Calendar.Month_Number) of String3 :=
-         ("JAN", "FEB", "MAR", "APR", "MAY", "JUN",
-          "JUL", "AUG", "SEP", "OCT", "NOV", "DEC");
+         ["JAN", "FEB", "MAR", "APR", "MAY", "JUN",
+          "JUL", "AUG", "SEP", "OCT", "NOV", "DEC"];
       --  Short version of the month names, used when parsing date strings
 
       S : String := Str;
index f127ded418794a19d5750454a17366862a60bce5..2527c9b0e3f87517e4cc4e9fd0422da549c551f0 100644 (file)
@@ -167,7 +167,7 @@ package body GNAT.CGI.Debug is
 
    package body HTML_IO is
 
-      NL : constant String := (1 => ASCII.LF);
+      NL : constant String := [ASCII.LF];
 
       function Bold (S : String) return String;
       --  Returns S as an HTML bold string
@@ -270,7 +270,7 @@ package body GNAT.CGI.Debug is
 
       function Title (IO : Format; Str : String) return String is
          Spaces : constant Natural := (80 - Str'Length) / 2;
-         Indent : constant String (1 .. Spaces) := (others => ' ');
+         Indent : constant String (1 .. Spaces) := [others => ' '];
       begin
          return Indent & Str & New_Line (IO);
       end Title;
index 7f7040b64d88d3e26f6ce29fef3a063f39dcd38f..4cbfd57ccff3b753b585f72e96960c2aaf52b30a 100644 (file)
@@ -1063,7 +1063,7 @@ package body GNAT.Command_Line is
       Parser.In_Expansion     := False;
       Parser.Switch_Character := Switch_Char;
       Parser.Stop_At_First    := Stop_At_First_Non_Switch;
-      Parser.Section          := (others => 1);
+      Parser.Section          := [others => 1];
 
       --  If we are using sections, we have to preprocess the command line to
       --  delimit them. A section can be repeated, so we just give each item
@@ -3225,7 +3225,7 @@ package body GNAT.Command_Line is
                if N /= "" then
                   Put (" ");
                   Put (N);
-                  Put ((1 .. Max_Len - N'Length + 1 => ' '));
+                  Put ([1 .. Max_Len - N'Length + 1 => ' ']);
 
                   if Config.Switches (S).Help /= null then
                      Put (Config.Switches (S).Help.all);
@@ -3243,8 +3243,8 @@ package body GNAT.Command_Line is
                if Config.Aliases (A).Section.all = Section then
                   Put (" ");
                   Put (Config.Aliases (A).Alias.all);
-                  Put ((1 .. Max_Len - Config.Aliases (A).Alias'Length + 1
-                       => ' '));
+                  Put ([1 .. Max_Len - Config.Aliases (A).Alias'Length + 1
+                       => ' ']);
                   Put ("Equivalent to " & Config.Aliases (A).Expansion.all);
                   New_Line;
                end if;
index e5f493e1128ee7d3bca2c7ae5b1fe4dfc988beb1..37384329607594a0ee8d8ec387587e1b77ef2670 100644 (file)
@@ -1097,11 +1097,11 @@ private
       --  This type and this variable are provided to store the current switch
       --  and parameter.
 
-      Is_Switch : Is_Switch_Type (1 .. Arg_Count) := (others => False);
+      Is_Switch : Is_Switch_Type (1 .. Arg_Count) := [others => False];
       --  Indicates wich arguments on the command line are considered not be
       --  switches or parameters to switches (leaving e.g. filenames,...)
 
-      Section : Section_Type (1 .. Arg_Count) := (others => 1);
+      Section : Section_Type (1 .. Arg_Count) := [others => 1];
       --  Contains the number of the section associated with the current
       --  switch. If this number is 0, then it is a section delimiter, which is
       --  never returned by GetOpt.
index 0092139f83a01facede9a05f99ae862243b5028b..5d707cae7e3cec9df4ccace0c86dfb28f7318df6 100644 (file)
@@ -1148,7 +1148,7 @@ package body GNAT.Debug_Pools is
       Modulo : constant Storage_Count :=
                  Size_In_Storage_Elements mod Dead_Bytes;
    begin
-      M.all := (others => Dead);
+      M.all := [others => Dead];
 
       --  Any bytes left (up to three of them)
 
@@ -1942,7 +1942,7 @@ package body GNAT.Debug_Pools is
          Grand_Total : Float;
 
          Max  : array (1 .. Size) of Traceback_Htable_Elem_Ptr :=
-           (others => null);
+           [others => null];
          --  Sorted array for the biggest memory users
 
          Allocated_In_Pool : Byte_Count;
index b9457318d0022017a22e2299ac30c674a426d6af..89ede30d01146479576c6d3305e1f912b7ab23b3 100644 (file)
@@ -351,7 +351,7 @@ package body GNAT.Expect is
       Full_Buffer : Boolean := False)
    is
       N           : Expect_Match;
-      Descriptors : Array_Of_Pd := (1 => Descriptor'Unrestricted_Access);
+      Descriptors : Array_Of_Pd := [Descriptor'Unrestricted_Access];
       Try_Until   : constant Time := Clock + Duration (Timeout) / 1000.0;
       Timeout_Tmp : Integer := Timeout;
 
@@ -508,7 +508,7 @@ package body GNAT.Expect is
       Full_Buffer : Boolean := False)
    is
       N           : Expect_Match;
-      Descriptors : Array_Of_Pd := (1 => Descriptor'Unrestricted_Access);
+      Descriptors : Array_Of_Pd := [Descriptor'Unrestricted_Access];
 
    begin
       pragma Assert (Matched'First = 0);
@@ -1078,7 +1078,7 @@ package body GNAT.Expect is
 
    function Has_Process (Regexp : Multiprocess_Regexp_Array) return Boolean is
    begin
-      return Regexp /= (Regexp'Range => (null, null));
+      return Regexp /= [Regexp'Range => (null, null)];
    end Has_Process;
 
    ---------------
@@ -1294,8 +1294,8 @@ package body GNAT.Expect is
       Add_LF       : Boolean := True;
       Empty_Buffer : Boolean := False)
    is
-      Line_Feed   : aliased constant String := (1 .. 1 => ASCII.LF);
-      Descriptors : Array_Of_Pd := (1 => Descriptor'Unrestricted_Access);
+      Line_Feed   : aliased constant String := [1 .. 1 => ASCII.LF];
+      Descriptors : Array_Of_Pd := [Descriptor'Unrestricted_Access];
 
       Result  : Expect_Match;
       Discard : Natural;
index 04539be026c6b2d2db5ed416f67f441078026438..51858ed0bcef2f0d37fada76f0745d9dc7ee43c1 100644 (file)
@@ -131,7 +131,7 @@ package body GNAT.Formatted_String is
       return Formatted_String'
         (Finalization.Controlled with
            D => new Data'(Format'Length, 1, 1,
-             Null_Unbounded_String, 0, 0, (0, 0), Format));
+             Null_Unbounded_String, 0, 0, [0, 0], Format));
    end "+";
 
    ---------
@@ -433,7 +433,7 @@ package body GNAT.Formatted_String is
 
       declare
          R : String (1 .. Natural'Max (Natural'Max (F_Spec.Width, Len),
-                                       Length (Res))) := (others => ' ');
+                                       Length (Res))) := [others => ' '];
       begin
          if F_Spec.Left_Justify then
             R (1 .. Length (Res)) := To_String (Res);
@@ -785,7 +785,7 @@ package body GNAT.Formatted_String is
 
          elsif F.Precision > E - S + 1 then
             Len := F.Precision - (E - S + 1);
-            Buffer (S - Len .. S - 1) := (others => '0');
+            Buffer (S - Len .. S - 1) := [others => '0'];
             S := S - Len;
          end if;
 
index cd8f7caa4d452f48f640b1d10660a4f781ea6cc8..310923fabce7585965024b9877ff177b93279703 100644 (file)
@@ -128,7 +128,7 @@ package body GNAT.Memory_Dump is
                           (Count - Ctr, 16, 0, Offset_Buf, Last);
                         Len := Last - 4;
 
-                        Line_Buf (1 .. AIL - Len - 2) := (others => '0');
+                        Line_Buf (1 .. AIL - Len - 2) := [others => '0'];
                         Line_Buf (AIL - Len - 1 .. AIL - 2) :=
                           Offset_Buf (4 .. Last - 1);
                         Line_Buf (AIL - 1 .. AIL) := ": ";
@@ -138,7 +138,7 @@ package body GNAT.Memory_Dump is
                      null;
                end case;
 
-               Line_Buf (AIL + 1 .. Line_Buf'Last) := (others => ' ');
+               Line_Buf (AIL + 1 .. Line_Buf'Last) := [others => ' '];
                Line_Buf (AIL + 3 * 16 + 1) := '"';
             end if;
 
index 2983201be47a17b8701c7df54cc963f9eda1517c..76887817014a826a17febf04387c204180faa2f7 100644 (file)
@@ -385,7 +385,7 @@ is
       Result : Image_String;
 
    begin
-      Result := (others => ' ');
+      Result := [others => ' '];
       Result (1 .. Sys_Max_Image_Width) := Image (Gen.Rep);
 
       if Gen.Have_Gaussian then
index 178b59b38e71c5298c2ace2ca7b53bf1f1eee2a6..70911c05bba956c8f5f60f630ed40d39bf66df28 100644 (file)
@@ -238,7 +238,7 @@ package body GNAT.Secure_Hashes is
                      mod FC.M_State.Block_Length;
          declare
             Pad : Stream_Element_Array (1 .. 1 + Zeroes + Size_Length) :=
-                    (1 => 128, others => 0);
+                    [1 => 128, others => 0];
 
             Index       : Stream_Element_Offset;
             First_Index : Stream_Element_Offset;
@@ -281,7 +281,7 @@ package body GNAT.Secure_Hashes is
             declare
                Outer_C : Context;
                Opad    : Stream_Element_Array :=
-                 (1 .. Stream_Element_Offset (Block_Length) => 16#5c#);
+                 [1 .. Stream_Element_Offset (Block_Length) => 16#5c#];
 
             begin
                for J in C.Key'Range loop
@@ -329,7 +329,7 @@ package body GNAT.Secure_Hashes is
 
             declare
                Ipad : Stream_Element_Array :=
-                 (1 .. Stream_Element_Offset (Block_Length) => 16#36#);
+                 [1 .. Stream_Element_Offset (Block_Length) => 16#36#];
 
             begin
                for J in C.Key'Range loop
index 148ecb1f56025df34c3223bf8caa12411196fb03..ca9fbfde8a23a330600272f70b2801f7e3844c98 100644 (file)
@@ -68,7 +68,7 @@ private
    Initial_D : constant := 16#10325476#;
 
    Initial_State : constant Hash_State.State :=
-                     (Initial_A, Initial_B, Initial_C, Initial_D);
+                     [Initial_A, Initial_B, Initial_C, Initial_D];
    --  Initialization vector from RFC 1321
 
 end GNAT.Secure_Hashes.MD5;
index 602032ff75a118bcdd5d4fd23c3213d0b35e52d2..3a2408863d34b83eeecac8db78b29e6e785c1841 100644 (file)
@@ -62,11 +62,11 @@ package GNAT.Secure_Hashes.SHA1 is
 private
 
    Initial_State : constant Hash_State.State :=
-                     (0 => 16#67452301#,
+                     [0 => 16#67452301#,
                       1 => 16#EFCDAB89#,
                       2 => 16#98BADCFE#,
                       3 => 16#10325476#,
-                      4 => 16#C3D2E1F0#);
+                      4 => 16#C3D2E1F0#];
    --  Initialization vector from FIPS PUB 180-3
 
 end GNAT.Secure_Hashes.SHA1;
index 4c9b0b7cd490f9461dce7dfebaf2a45668723e6a..c05e00eb6348c0bd7867a2466623590927264067 100644 (file)
@@ -192,7 +192,7 @@ private
    end record;
 
    Data_Rate_Value : constant array (Data_Rate) of Interfaces.C.unsigned :=
-                       (B75      =>        75,
+                       [B75      =>        75,
                         B110     =>       110,
                         B150     =>       150,
                         B300     =>       300,
@@ -217,7 +217,7 @@ private
                         B2500000 => 2_500_000,
                         B3000000 => 3_000_000,
                         B3500000 => 3_500_000,
-                        B4000000 => 4_000_000);
+                        B4000000 => 4_000_000];
 
    function To_C (Port : Serial_Port) return Serial_Port_Descriptor is
       (Port.H);
index dbcb1718df41f4ce344a9ac52b744105d5d8aa31..3d62b613e60ebe5f072c14855f30c1bfaa27e6f1 100644 (file)
@@ -80,7 +80,7 @@ package body GNAT.Serial_Communications is
    pragma Import (C, fcntl, "fcntl");
 
    C_Data_Rate : constant array (Data_Rate) of unsigned :=
-                   (B75      => OSC.B75,
+                   [B75      => OSC.B75,
                     B110     => OSC.B110,
                     B150     => OSC.B150,
                     B300     => OSC.B300,
@@ -105,18 +105,18 @@ package body GNAT.Serial_Communications is
                     B2500000 => OSC.B2500000,
                     B3000000 => OSC.B3000000,
                     B3500000 => OSC.B3500000,
-                    B4000000 => OSC.B4000000);
+                    B4000000 => OSC.B4000000];
 
    C_Bits      : constant array (Data_Bits) of unsigned :=
-                   (CS7 => OSC.CS7, CS8 => OSC.CS8);
+                   [CS7 => OSC.CS7, CS8 => OSC.CS8];
 
    C_Stop_Bits : constant array (Stop_Bits_Number) of unsigned :=
-                   (One => 0, Two => OSC.CSTOPB);
+                   [One => 0, Two => OSC.CSTOPB];
 
    C_Parity    : constant array (Parity_Check) of unsigned :=
-                   (None => 0,
+                   [None => 0,
                     Odd  => OSC.PARENB or OSC.PARODD,
-                    Even => OSC.PARENB);
+                    Even => OSC.PARENB];
 
    procedure Raise_Error (Message : String; Error : Integer := Errno);
    pragma No_Return (Raise_Error);
index f23075b292bf4e7fb68cbfbcd5598985e96389ea..de51e726264ca6014cf4b47d41e2a1f30dcaafab 100644 (file)
@@ -50,7 +50,7 @@ package GNAT.Secure_Hashes.SHA2_32 is
    --  SHA-224 and SHA-256 operate on 32-bit big endian words
 
    K : constant Hash_State.State (0 .. 63) :=
-         (16#428a2f98#, 16#71374491#, 16#b5c0fbcf#, 16#e9b5dba5#,
+         [16#428a2f98#, 16#71374491#, 16#b5c0fbcf#, 16#e9b5dba5#,
           16#3956c25b#, 16#59f111f1#, 16#923f82a4#, 16#ab1c5ed5#,
           16#d807aa98#, 16#12835b01#, 16#243185be#, 16#550c7dc3#,
           16#72be5d74#, 16#80deb1fe#, 16#9bdc06a7#, 16#c19bf174#,
@@ -65,7 +65,7 @@ package GNAT.Secure_Hashes.SHA2_32 is
           16#19a4c116#, 16#1e376c08#, 16#2748774c#, 16#34b0bcb5#,
           16#391c0cb3#, 16#4ed8aa4a#, 16#5b9cca4f#, 16#682e6ff3#,
           16#748f82ee#, 16#78a5636f#, 16#84c87814#, 16#8cc70208#,
-          16#90befffa#, 16#a4506ceb#, 16#bef9a3f7#, 16#c67178f2#);
+          16#90befffa#, 16#a4506ceb#, 16#bef9a3f7#, 16#c67178f2#];
    --  Constants from FIPS PUB 180-3
 
    function Sigma0 (X : Word) return Word;
@@ -86,23 +86,23 @@ package GNAT.Secure_Hashes.SHA2_32 is
       S1         => S1);
 
    SHA224_Init_State : constant Hash_State.State (0 .. 7) :=
-                         (0 => 16#c1059ed8#,
+                         [0 => 16#c1059ed8#,
                           1 => 16#367cd507#,
                           2 => 16#3070dd17#,
                           3 => 16#f70e5939#,
                           4 => 16#ffc00b31#,
                           5 => 16#68581511#,
                           6 => 16#64f98fa7#,
-                          7 => 16#befa4fa4#);
+                          7 => 16#befa4fa4#];
    SHA256_Init_State : constant Hash_State.State (0 .. 7) :=
-                         (0 => 16#6a09e667#,
+                         [0 => 16#6a09e667#,
                           1 => 16#bb67ae85#,
                           2 => 16#3c6ef372#,
                           3 => 16#a54ff53a#,
                           4 => 16#510e527f#,
                           5 => 16#9b05688c#,
                           6 => 16#1f83d9ab#,
-                          7 => 16#5be0cd19#);
+                          7 => 16#5be0cd19#];
    --  Initialization vectors from FIPS PUB 180-3
 
 end GNAT.Secure_Hashes.SHA2_32;
index 1d670070d62687084f11fae1cbc92ab42dbe8c6d..8440e5d08b29170aae12d674d105b969ea7f3170 100644 (file)
@@ -50,7 +50,7 @@ package GNAT.Secure_Hashes.SHA2_64 is
    --  SHA-384 and SHA-512 operate on 64-bit big endian words
 
    K : Hash_State.State (0 .. 79) :=
-         (16#428a2f98d728ae22#, 16#7137449123ef65cd#,
+         [16#428a2f98d728ae22#, 16#7137449123ef65cd#,
           16#b5c0fbcfec4d3b2f#, 16#e9b5dba58189dbbc#,
           16#3956c25bf348b538#, 16#59f111f1b605d019#,
           16#923f82a4af194f9b#, 16#ab1c5ed5da6d8118#,
@@ -89,7 +89,7 @@ package GNAT.Secure_Hashes.SHA2_64 is
           16#28db77f523047d84#, 16#32caab7b40c72493#,
           16#3c9ebe0a15c9bebc#, 16#431d67c49c100d4c#,
           16#4cc5d4becb3e42b6#, 16#597f299cfc657e2a#,
-          16#5fcb6fab3ad6faec#, 16#6c44198c4a475817#);
+          16#5fcb6fab3ad6faec#, 16#6c44198c4a475817#];
    --  Constants from FIPS PUB 180-3
 
    function Sigma0 (X : Word) return Word;
@@ -110,23 +110,23 @@ package GNAT.Secure_Hashes.SHA2_64 is
       S1         => S1);
 
    SHA384_Init_State : constant Hash_State.State :=
-                         (0 => 16#cbbb9d5dc1059ed8#,
+                         [0 => 16#cbbb9d5dc1059ed8#,
                           1 => 16#629a292a367cd507#,
                           2 => 16#9159015a3070dd17#,
                           3 => 16#152fecd8f70e5939#,
                           4 => 16#67332667ffc00b31#,
                           5 => 16#8eb44a8768581511#,
                           6 => 16#db0c2e0d64f98fa7#,
-                          7 => 16#47b5481dbefa4fa4#);
+                          7 => 16#47b5481dbefa4fa4#];
    SHA512_Init_State : constant Hash_State.State :=
-                         (0 => 16#6a09e667f3bcc908#,
+                         [0 => 16#6a09e667f3bcc908#,
                           1 => 16#bb67ae8584caa73b#,
                           2 => 16#3c6ef372fe94f82b#,
                           3 => 16#a54ff53a5f1d36f1#,
                           4 => 16#510e527fade682d1#,
                           5 => 16#9b05688c2b3e6c1f#,
                           6 => 16#1f83d9abfb41bd6b#,
-                          7 => 16#5be0cd19137e2179#);
+                          7 => 16#5be0cd19137e2179#];
    --  Initialization vectors from FIPS PUB 180-3
 
 end GNAT.Secure_Hashes.SHA2_64;
index 75a2b27414fe6b67aa7dd118345fc99f65f186e8..c603a2db35a26cf81f5ccb94f6aa2f3f5a0c4fdb 100644 (file)
@@ -71,31 +71,31 @@ package body GNAT.Sockets is
    --  Correspondence tables
 
    Levels : constant array (Level_Type) of C.int :=
-              (Socket_Level               => SOSC.SOL_SOCKET,
+              [Socket_Level               => SOSC.SOL_SOCKET,
                IP_Protocol_For_IP_Level   => SOSC.IPPROTO_IP,
                IP_Protocol_For_IPv6_Level => SOSC.IPPROTO_IPV6,
                IP_Protocol_For_UDP_Level  => SOSC.IPPROTO_UDP,
                IP_Protocol_For_TCP_Level  => SOSC.IPPROTO_TCP,
                IP_Protocol_For_ICMP_Level => SOSC.IPPROTO_ICMP,
                IP_Protocol_For_IGMP_Level => SOSC.IPPROTO_IGMP,
-               IP_Protocol_For_RAW_Level  => SOSC.IPPROTO_RAW);
+               IP_Protocol_For_RAW_Level  => SOSC.IPPROTO_RAW];
 
    Modes : constant array (Mode_Type) of C.int :=
-             (Socket_Stream   => SOSC.SOCK_STREAM,
+             [Socket_Stream   => SOSC.SOCK_STREAM,
               Socket_Datagram => SOSC.SOCK_DGRAM,
-              Socket_Raw      => SOSC.SOCK_RAW);
+              Socket_Raw      => SOSC.SOCK_RAW];
 
    Shutmodes : constant array (Shutmode_Type) of C.int :=
-                 (Shut_Read       => SOSC.SHUT_RD,
+                 [Shut_Read       => SOSC.SHUT_RD,
                   Shut_Write      => SOSC.SHUT_WR,
-                  Shut_Read_Write => SOSC.SHUT_RDWR);
+                  Shut_Read_Write => SOSC.SHUT_RDWR];
 
    Requests : constant array (Request_Name) of SOSC.IOCTL_Req_T :=
-                (Non_Blocking_IO => SOSC.FIONBIO,
-                 N_Bytes_To_Read => SOSC.FIONREAD);
+                [Non_Blocking_IO => SOSC.FIONBIO,
+                 N_Bytes_To_Read => SOSC.FIONREAD];
 
    Options : constant array (Specific_Option_Name) of C.int :=
-               (Keep_Alive          => SOSC.SO_KEEPALIVE,
+               [Keep_Alive          => SOSC.SO_KEEPALIVE,
                 Keep_Alive_Count    => SOSC.TCP_KEEPCNT,
                 Keep_Alive_Idle     => SOSC.TCP_KEEPIDLE,
                 Keep_Alive_Interval => SOSC.TCP_KEEPINTVL,
@@ -120,15 +120,15 @@ package body GNAT.Sockets is
                 IPv6_Only           => SOSC.IPV6_V6ONLY,
                 Send_Timeout        => SOSC.SO_SNDTIMEO,
                 Receive_Timeout     => SOSC.SO_RCVTIMEO,
-                Busy_Polling        => SOSC.SO_BUSY_POLL);
+                Busy_Polling        => SOSC.SO_BUSY_POLL];
    --  ??? Note: for OpenSolaris, Receive_Packet_Info should be IP_RECVPKTINFO,
    --  but for Linux compatibility this constant is the same as IP_PKTINFO.
 
    Flags : constant array (0 .. 3) of C.int :=
-             (0 => SOSC.MSG_OOB,     --  Process_Out_Of_Band_Data
+             [0 => SOSC.MSG_OOB,     --  Process_Out_Of_Band_Data
               1 => SOSC.MSG_PEEK,    --  Peek_At_Incoming_Data
               2 => SOSC.MSG_WAITALL, --  Wait_For_A_Full_Reception
-              3 => SOSC.MSG_EOR);    --  Send_End_Of_Record
+              3 => SOSC.MSG_EOR];    --  Send_End_Of_Record
 
    Socket_Error_Id : constant Exception_Id := Socket_Error'Identity;
    Host_Error_Id   : constant Exception_Id := Host_Error'Identity;
@@ -1184,8 +1184,8 @@ package body GNAT.Sockets is
       Numeric_Serv : Boolean := False) return Host_Service
    is
       SA  : aliased Sockaddr;
-      H   : aliased C.char_array := (1 .. SOSC.NI_MAXHOST => C.nul);
-      S   : aliased C.char_array := (1 .. SOSC.NI_MAXSERV => C.nul);
+      H   : aliased C.char_array := [1 .. SOSC.NI_MAXHOST => C.nul];
+      S   : aliased C.char_array := [1 .. SOSC.NI_MAXSERV => C.nul];
       RC  : C.int;
       Len : C.int;
    begin
@@ -1621,7 +1621,7 @@ package body GNAT.Sockets is
             when Family_Inet   => 4 * Value.Sin_V4'Length,
             when Family_Inet6  => 6 * 5 + 4 * 4);
             --  1234:1234:1234:1234:1234:1234:123.123.123.123
-      Dst : aliased C.char_array := (1 .. C.size_t (Size) => C.nul);
+      Dst : aliased C.char_array := [1 .. C.size_t (Size) => C.nul];
       Ia  : aliased In_Addr_Union (Value.Family);
    begin
       case Value.Family is
index d4265a2cb5b6285924096531beb392b986835120..443b61c3cb41bec655dd450bdc00567a731cd701 100644 (file)
@@ -506,7 +506,7 @@ package GNAT.Sockets is
    --  Octet for Internet address
 
    Inet_Addr_Bytes_Length : constant array (Family_Inet_4_6) of Natural :=
-     (Family_Inet => 4, Family_Inet6 => 16);
+     [Family_Inet => 4, Family_Inet6 => 16];
 
    type Inet_Addr_Bytes is array (Natural range <>) of Inet_Addr_Comp_Type;
 
@@ -521,10 +521,10 @@ package GNAT.Sockets is
    type Inet_Addr_Type (Family : Family_Inet_4_6 := Family_Inet) is record
       case Family is
          when Family_Inet =>
-            Sin_V4 : Inet_Addr_V4_Type := (others => 0);
+            Sin_V4 : Inet_Addr_V4_Type := [others => 0];
 
          when Family_Inet6 =>
-            Sin_V6 : Inet_Addr_V6_Type := (others => 0);
+            Sin_V6 : Inet_Addr_V6_Type := [others => 0];
 
       end case;
    end record;
@@ -571,7 +571,7 @@ package GNAT.Sockets is
    --  Idem for IPv6 protocol
 
    IPv4_To_IPv6_Prefix : constant Inet_Addr_Bytes :=
-     (1 .. 10 => 0, 11 .. 12 => 255);
+     [1 .. 10 => 0, 11 .. 12 => 255];
    --  Prefix for IPv4 mapped to IPv6 addresses
 
    --  Functions to handle masks and prefixes
@@ -1529,32 +1529,32 @@ private
    No_Port  : constant Port_Type := 0;
 
    Any_Inet_Addr       : constant Inet_Addr_Type :=
-                           (Family_Inet, (others => 0));
+                           (Family_Inet, [others => 0]);
    Any_Inet6_Addr      : constant Inet_Addr_Type :=
-                           (Family_Inet6, (others => 0));
+                           (Family_Inet6, [others => 0]);
    No_Inet_Addr        : constant Inet_Addr_Type :=
-                           (Family_Inet, (others => 0));
+                           (Family_Inet, [others => 0]);
    Broadcast_Inet_Addr : constant Inet_Addr_Type :=
-                           (Family_Inet, (others => 255));
+                           (Family_Inet, [others => 255]);
    Loopback_Inet_Addr  : constant Inet_Addr_Type :=
-                           (Family_Inet, (127, 0, 0, 1));
+                           (Family_Inet, [127, 0, 0, 1]);
    Loopback_Inet6_Addr : constant Inet_Addr_Type :=
                            (Family_Inet6,
-                            (0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1));
+                            [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1]);
 
    Unspecified_Group_Inet_Addr : constant Inet_Addr_Type :=
-                                   (Family_Inet, (224, 0, 0, 0));
+                                   (Family_Inet, [224, 0, 0, 0]);
    All_Hosts_Group_Inet_Addr   : constant Inet_Addr_Type :=
-                                   (Family_Inet, (224, 0, 0, 1));
+                                   (Family_Inet, [224, 0, 0, 1]);
    All_Routers_Group_Inet_Addr : constant Inet_Addr_Type :=
-                                   (Family_Inet, (224, 0, 0, 2));
+                                   (Family_Inet, [224, 0, 0, 2]);
 
    Unspecified_Group_Inet6_Addr : constant Inet_Addr_Type :=
-     (Family_Inet6, (255, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0));
+     (Family_Inet6, [255, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
    All_Hosts_Group_Inet6_Addr   : constant Inet_Addr_Type :=
-     (Family_Inet6, (255, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1));
+     (Family_Inet6, [255, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1]);
    All_Routers_Group_Inet6_Addr : constant Inet_Addr_Type :=
-     (Family_Inet6, (255, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2));
+     (Family_Inet6, [255, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2]);
 
    No_Sock_Addr : constant Sock_Addr_Type := (Family_Inet, No_Inet_Addr, 0);
 
index 3f153af108776a4ed382f19edc45763d021f854c..1592594926c530fbd2f4dcfee0b65280417d5c7f 100644 (file)
@@ -36,7 +36,7 @@ with GNAT.Sockets.Thin;
 package body GNAT.Sockets.Poll is
 
    To_C : constant array (Wait_Event_Type) of Events_Type :=
-            (Input => SOC.POLLIN or SOC.POLLPRI, Output => SOC.POLLOUT);
+            [Input => SOC.POLLIN or SOC.POLLPRI, Output => SOC.POLLOUT];
    --  To convert Wait_Event_Type to C I/O events flags
 
    procedure Set_Mode (Item : out Pollfd; Mode : Wait_Event_Set);
@@ -50,11 +50,11 @@ package body GNAT.Sockets.Poll is
    --  raise Constraint_Error if Index is more than number of sockets in Self
 
    function Status (Item : Pollfd) return Event_Set is
-     (Input           => (Item.REvents and To_C (Input)) /= 0,
-      Output          => (Item.REvents and To_C (Output)) /= 0,
-      Error           => (Item.REvents and SOC.POLLERR) /= 0,
-      Hang_Up         => (Item.REvents and SOC.POLLHUP) /= 0,
-      Invalid_Request => (Item.REvents and SOC.POLLNVAL) /= 0);
+     ([Input           => (Item.REvents and To_C (Input)) /= 0,
+       Output          => (Item.REvents and To_C (Output)) /= 0,
+       Error           => (Item.REvents and SOC.POLLERR) /= 0,
+       Hang_Up         => (Item.REvents and SOC.POLLHUP) /= 0,
+       Invalid_Request => (Item.REvents and SOC.POLLNVAL) /= 0]);
    --  Get I/O events from C word
 
    procedure Wait
@@ -188,8 +188,8 @@ package body GNAT.Sockets.Poll is
    begin
       Check_Range (Self, Index);
       return
-        (Input  => (Self.Fds (Index).Events and To_C (Input)) /= 0,
-         Output => (Self.Fds (Index).Events and To_C (Output)) /= 0);
+        [Input  => (Self.Fds (Index).Events and To_C (Input)) /= 0,
+         Output => (Self.Fds (Index).Events and To_C (Output)) /= 0];
    end Get_Events;
 
    ------------
index 71ce1bbff9c90e55631821c3e5ea0120fe92b34b..348cc6f710be0e19a626036f0a1a7caaa42c17e4 100644 (file)
@@ -171,10 +171,10 @@ package GNAT.Sockets.Poll is
 
 private
 
-   Input_Event  : constant Wait_Event_Set := (Input => True, Output => False);
-   Output_Event : constant Wait_Event_Set := (Input => False, Output => True);
-   Both_Events  : constant Wait_Event_Set := (others => True);
-   Error_Event  : constant Wait_Event_Set := (others => False);
+   Input_Event  : constant Wait_Event_Set := [Input => True, Output => False];
+   Output_Event : constant Wait_Event_Set := [Input => False, Output => True];
+   Both_Events  : constant Wait_Event_Set := [others => True];
+   Error_Event  : constant Wait_Event_Set := [others => False];
 
    package SOC renames System.OS_Constants;
 
index b48657ba2afbc30147b0156031806a8ac95410d6..761bcb19e6e40c4c20409687372e1887b8c473a9 100644 (file)
@@ -75,16 +75,16 @@ package GNAT.Sockets.Thin_Common is
    -------------------------------------------
 
    Families : constant array (Family_Type) of C.int :=
-                (Family_Unspec => SOSC.AF_UNSPEC,
+                [Family_Unspec => SOSC.AF_UNSPEC,
                  Family_Unix   => SOSC.AF_UNIX,
                  Family_Inet   => SOSC.AF_INET,
-                 Family_Inet6  => SOSC.AF_INET6);
+                 Family_Inet6  => SOSC.AF_INET6];
 
    Lengths  : constant array (Family_Type) of C.unsigned_char :=
-                (Family_Unspec => 0,
+                [Family_Unspec => 0,
                  Family_Unix   => SOSC.SIZEOF_sockaddr_un,
                  Family_Inet   => SOSC.SIZEOF_sockaddr_in,
-                 Family_Inet6  => SOSC.SIZEOF_sockaddr_in6);
+                 Family_Inet6  => SOSC.SIZEOF_sockaddr_in6];
 
    ----------------------------
    -- Generic socket address --
@@ -160,7 +160,7 @@ package GNAT.Sockets.Thin_Common is
          Sin_Addr : In_Addr := (others => 0);
          --  IPv4 address
 
-         Sin_Zero : C.char_array (1 .. 8) := (others => C.nul);
+         Sin_Zero : C.char_array (1 .. 8) := [others => C.nul];
          --  Padding
          --
          --  Note that some platforms require that all unused (reserved) bytes
@@ -174,7 +174,7 @@ package GNAT.Sockets.Thin_Common is
          --  Port in network byte order
 
          Sin6_FlowInfo : Interfaces.Unsigned_32 := 0;
-         Sin6_Addr     : In6_Addr := (others => 0);
+         Sin6_Addr     : In6_Addr := [others => 0];
          Sin6_Scope_Id : Interfaces.Unsigned_32 := 0;
 
       when Family_Unix =>
index 97cfdf970806bd28d6e48b6f21cd3cd4c54e62c8..353a92d104fbfb79ef960d0956b6eb31ceecaea4 100644 (file)
@@ -367,7 +367,7 @@ package body GNAT.Spitbol.Patterns is
    --  one character on success, and not to make any entries on the stack.
 
    OK_For_Simple_Arbno : constant array (Pattern_Code) of Boolean :=
-     (PC_Any_CS    |
+     [PC_Any_CS    |
       PC_Any_CH    |
       PC_Any_VF    |
       PC_Any_VP    |
@@ -387,7 +387,7 @@ package body GNAT.Spitbol.Patterns is
       PC_String_4  |
       PC_String_5  |
       PC_String_6   => True,
-      others        => False);
+      others        => False];
 
    -------------------------------
    -- The Pattern History Stack --
index cf96e25536a676c7c0899c8d1d6e022ca98e8c3a..33fa1aea06b776f9a2c8f2a43dc101b1b1342075 100644 (file)
@@ -61,7 +61,7 @@ package Interfaces.COBOL is
 
    type COBOL_Character is new Character;
 
-   Ada_To_COBOL : array (Standard.Character) of COBOL_Character := (
+   Ada_To_COBOL : array (Standard.Character) of COBOL_Character := [
      COBOL_Character'Val (000), COBOL_Character'Val (001),
      COBOL_Character'Val (002), COBOL_Character'Val (003),
      COBOL_Character'Val (004), COBOL_Character'Val (005),
@@ -189,9 +189,9 @@ package Interfaces.COBOL is
      COBOL_Character'Val (248), COBOL_Character'Val (249),
      COBOL_Character'Val (250), COBOL_Character'Val (251),
      COBOL_Character'Val (252), COBOL_Character'Val (253),
-     COBOL_Character'Val (254), COBOL_Character'Val (255));
+     COBOL_Character'Val (254), COBOL_Character'Val (255)];
 
-   COBOL_To_Ada : array (COBOL_Character) of Standard.Character := (
+   COBOL_To_Ada : array (COBOL_Character) of Standard.Character := [
      Standard.Character'Val (000), Standard.Character'Val (001),
      Standard.Character'Val (002), Standard.Character'Val (003),
      Standard.Character'Val (004), Standard.Character'Val (005),
@@ -319,7 +319,7 @@ package Interfaces.COBOL is
      Standard.Character'Val (248), Standard.Character'Val (249),
      Standard.Character'Val (250), Standard.Character'Val (251),
      Standard.Character'Val (252), Standard.Character'Val (253),
-     Standard.Character'Val (254), Standard.Character'Val (255));
+     Standard.Character'Val (254), Standard.Character'Val (255)];
 
    type Alphanumeric is array (Positive range <>) of COBOL_Character;
    --  pragma Pack (Alphanumeric);
index 8b8acc9c30cbd6ed5006db2c411881e19693f10b..43648888f6923c9e7b4e8f1c3b9e910dba49b750 100644 (file)
@@ -48,7 +48,7 @@ package body Interfaces.Packed_Decimal is
    --  using table look up in this direction because divides are expensive.
 
    Packed_Byte : constant array (00 .. 99) of Unsigned_8 :=
-      (16#00#, 16#01#, 16#02#, 16#03#, 16#04#,
+      [16#00#, 16#01#, 16#02#, 16#03#, 16#04#,
        16#05#, 16#06#, 16#07#, 16#08#, 16#09#,
        16#10#, 16#11#, 16#12#, 16#13#, 16#14#,
        16#15#, 16#16#, 16#17#, 16#18#, 16#19#,
@@ -67,7 +67,7 @@ package body Interfaces.Packed_Decimal is
        16#80#, 16#81#, 16#82#, 16#83#, 16#84#,
        16#85#, 16#86#, 16#87#, 16#88#, 16#89#,
        16#90#, 16#91#, 16#92#, 16#93#, 16#94#,
-       16#95#, 16#96#, 16#97#, 16#98#, 16#99#);
+       16#95#, 16#96#, 16#97#, 16#98#, 16#99#];
 
    ---------------------
    -- Int32_To_Packed --
index d68767fcb49eebfc58933eaeb59c2921e5701d9c..bcfa1b707f3b81cbcb30fe645b3af79b160d613d 100644 (file)
@@ -91,7 +91,7 @@ package Interfaces.Packed_Decimal is
    --  Range of possible byte lengths
 
    Packed_Size : constant array (1 .. 18) of Byte_Length :=
-      (01 => 01,    -- Length in bytes for digits 1
+      [01 => 01,    -- Length in bytes for digits 1
        02 => 02,    -- Length in bytes for digits 2
        03 => 02,    -- Length in bytes for digits 2
        04 => 03,    -- Length in bytes for digits 2
@@ -108,7 +108,7 @@ package Interfaces.Packed_Decimal is
        15 => 08,    -- Length in bytes for digits 2
        16 => 09,    -- Length in bytes for digits 2
        17 => 09,    -- Length in bytes for digits 2
-       18 => 10);   -- Length in bytes for digits 2
+       18 => 10];   -- Length in bytes for digits 2
 
    -------------------------
    -- Conversion Routines --
index 45290d3be4ed8b8c3c2d6d00123b7a39917512bd..05353417552719d018f0cae90f663f4645f59ac1 100644 (file)
@@ -59,14 +59,14 @@ package body System.Bit_Ops is
    --  The following is an array of masks used to mask the final byte, either
    --  at the high end (big-endian case) or the low end (little-endian case).
 
-   Masks : constant array (1 .. 7) of Packed_Byte := (
+   Masks : constant array (1 .. 7) of Packed_Byte := [
      (1 - LE) * 2#1000_0000# + LE * 2#0000_0001#,
      (1 - LE) * 2#1100_0000# + LE * 2#0000_0011#,
      (1 - LE) * 2#1110_0000# + LE * 2#0000_0111#,
      (1 - LE) * 2#1111_0000# + LE * 2#0000_1111#,
      (1 - LE) * 2#1111_1000# + LE * 2#0001_1111#,
      (1 - LE) * 2#1111_1100# + LE * 2#0011_1111#,
-     (1 - LE) * 2#1111_1110# + LE * 2#0111_1111#);
+     (1 - LE) * 2#1111_1110# + LE * 2#0111_1111#];
 
    -----------------------
    -- Local Subprograms --
index 9f34ed599789714256e75d6802c7bea5f21d7942..ea4446a4f09cbdfeca6730478002d1b2a0ef24e5 100644 (file)
@@ -41,7 +41,7 @@ package body System.CRC32 is
    --  than processing the byte bit by bit.
 
    Table : constant array (CRC32 range 0 .. 255) of CRC32 :=
-     (16#0000_0000#, 16#7707_3096#, 16#EE0E_612C#, 16#9909_51BA#,
+     [16#0000_0000#, 16#7707_3096#, 16#EE0E_612C#, 16#9909_51BA#,
       16#076D_C419#, 16#706A_F48F#, 16#E963_A535#, 16#9E64_95A3#,
       16#0EDB_8832#, 16#79DC_B8A4#, 16#E0D5_E91E#, 16#97D2_D988#,
       16#09B6_4C2B#, 16#7EB1_7CBD#, 16#E7B8_2D07#, 16#90BF_1D91#,
@@ -104,7 +104,7 @@ package body System.CRC32 is
       16#BDBD_F21C#, 16#CABA_C28A#, 16#53B3_9330#, 16#24B4_A3A6#,
       16#BAD0_3605#, 16#CDD7_0693#, 16#54DE_5729#, 16#23D9_67BF#,
       16#B366_7A2E#, 16#C461_4AB8#, 16#5D68_1B02#, 16#2A6F_2B94#,
-      16#B40B_BE37#, 16#C30C_8EA1#, 16#5A05_DF1B#, 16#2D02_EF8D#);
+      16#B40B_BE37#, 16#C30C_8EA1#, 16#5A05_DF1B#, 16#2D02_EF8D#];
 
    ---------------
    -- Get_Value --
index 957efd55110a779851561d8a9f15a3c98c53c47a..92af09d09daef01f96f178f7e46c8369e97580b9 100644 (file)
@@ -883,7 +883,7 @@ package body System.Generic_Array_Operations is
       return R : Matrix (First_1 .. Check_Unit_Last (First_1, Order, First_1),
                          First_2 .. Check_Unit_Last (First_2, Order, First_2))
       do
-         R := (others => (others => Zero));
+         R := [others => [others => Zero]];
 
          for J in 0 .. Order - 1 loop
             R (First_1 + J, First_2 + J) := One;
@@ -902,7 +902,7 @@ package body System.Generic_Array_Operations is
    is
    begin
       return R : Vector (First .. Check_Unit_Last (Index, Order, First)) do
-         R := (others => Zero);
+         R := [others => Zero];
          R (Index) := One;
       end return;
    end Unit_Vector;
index 8d03f0abcc557f75855c02ac0421e3ed3140276a..47d8311a45d5656a23a6afb8d5c1c846675cc0e2 100644 (file)
@@ -50,10 +50,10 @@ package body System.Generic_Bignums is
 
    subtype LLI is Long_Long_Integer;
 
-   One_Data : constant Digit_Vector (1 .. 1) := (1 => 1);
+   One_Data : constant Digit_Vector (1 .. 1) := [1];
    --  Constant one
 
-   Zero_Data : constant Digit_Vector (1 .. 0) := (1 .. 0 => 0);
+   Zero_Data : constant Digit_Vector (1 .. 0) := [];
    --  Constant zero
 
    -----------------------
@@ -332,7 +332,7 @@ package body System.Generic_Bignums is
       elsif X.Len = 1 and then X.D (1) = 2 and then Y.D (1) < 32 then
          declare
             D : constant Digit_Vector (1 .. 1) :=
-                  (1 => Shift_Left (SD'(1), Natural (Y.D (1))));
+                  [Shift_Left (SD'(1), Natural (Y.D (1)))];
          begin
             return Normalize (D, X.Neg);
          end;
@@ -573,7 +573,7 @@ package body System.Generic_Bignums is
    -------------
 
    function Big_Mul (X, Y : Bignum) return Big_Integer is
-      Result : Digit_Vector (1 .. X.Len + Y.Len) := (others => 0);
+      Result : Digit_Vector (1 .. X.Len + Y.Len) := [others => 0];
       --  Accumulate result (max length of result is sum of operand lengths)
 
       L : Length;
@@ -1149,22 +1149,22 @@ package body System.Generic_Bignums is
 
    begin
       if X = 0 then
-         return Allocate_Big_Integer ((1 .. 0 => <>), False);
+         return Allocate_Big_Integer ([], False);
 
       --  One word result
 
       elsif X in -(2 ** 32 - 1) .. +(2 ** 32 - 1) then
-         return Allocate_Big_Integer ((1 => SD (abs X)), X < 0);
+         return Allocate_Big_Integer ([SD (abs X)], X < 0);
 
       --  Large negative number annoyance
 
       elsif X = -2 ** 63 then
-         return Allocate_Big_Integer ((2 ** 31, 0), True);
+         return Allocate_Big_Integer ([2 ** 31, 0], True);
 
       elsif Long_Long_Long_Integer'Size = 128
         and then X = Long_Long_Long_Integer'First
       then
-         return Allocate_Big_Integer ((2 ** 31, 0, 0, 0), True);
+         return Allocate_Big_Integer ([2 ** 31, 0, 0, 0], True);
 
       --  Other negative numbers
 
@@ -1196,17 +1196,17 @@ package body System.Generic_Bignums is
    function To_Bignum (X : Unsigned_128) return Big_Integer is
    begin
       if X = 0 then
-         return Allocate_Big_Integer ((1 .. 0 => <>), False);
+         return Allocate_Big_Integer ([], False);
 
       --  One word result
 
       elsif X < 2 ** 32 then
-         return Allocate_Big_Integer ((1 => SD (X)), False);
+         return Allocate_Big_Integer ([SD (X)], False);
 
       --  Two word result
 
       elsif Shift_Right (X, 32) < 2 ** 32 then
-         return Allocate_Big_Integer ((SD (X / Base), SD (X mod Base)), False);
+         return Allocate_Big_Integer ([SD (X / Base), SD (X mod Base)], False);
 
       --  Three or four word result
 
@@ -1241,7 +1241,7 @@ package body System.Generic_Bignums is
    function To_String
      (X : Bignum; Width : Natural := 0; Base : Positive := 10) return String
    is
-      Big_Base : aliased Bignum_Data := (1, False, (1 => SD (Base)));
+      Big_Base : aliased Bignum_Data := (1, False, [SD (Base)]);
 
       function Add_Base (S : String) return String;
       --  Add base information if Base /= 10
@@ -1285,7 +1285,7 @@ package body System.Generic_Bignums is
       function Image (Arg : Bignum) return String is
       begin
          if Big_LT (Arg, Big_Base'Unchecked_Access) then
-            return (1 => Hex_Chars (Natural (From_Bignum (Arg))));
+            return [Hex_Chars (Natural (From_Bignum (Arg)))];
          else
             declare
                Div    : aliased Big_Integer;
@@ -1315,8 +1315,8 @@ package body System.Generic_Bignums is
          Min_Length : Natural;
          Char       : Character := ' ') return String is
       begin
-         return (1 .. Integer'Max (Integer (Min_Length) - Str'Length, 0)
-                        => Char) & Str;
+         return [1 .. Integer'Max (Integer (Min_Length) - Str'Length, 0)
+                        => Char] & Str;
       end Leading_Padding;
 
       Zero : aliased Bignum_Data := (0, False, D => Zero_Data);
index af2db2f8eab892c27f3fb6f71ca59257d28e92d2..90bfc130ce3134e3a51c2b1c70c9630effcddde4 100644 (file)
@@ -173,7 +173,7 @@ package body System.HTable is
       begin
          --  Use an aggregate for efficiency reasons
 
-         Table := (others => Null_Ptr);
+         Table := [others => Null_Ptr];
       end Reset;
 
       ---------
index bfcae49620703bd31a71bc0d1cd448fecc8dc335..8c58b19fe019e5b57cfa7f5ba15d0c167e65b5f0 100644 (file)
@@ -48,7 +48,7 @@ package body System.Img_Char is
         range Character'Val (16#00#) .. Character'Val (16#1F#);
 
       C0 : constant array (C0_Range) of Cname :=
-              (Character'Val (16#00#) => "NUL",
+              [Character'Val (16#00#) => "NUL",
                Character'Val (16#01#) => "SOH",
                Character'Val (16#02#) => "STX",
                Character'Val (16#03#) => "ETX",
@@ -79,13 +79,13 @@ package body System.Img_Char is
                Character'Val (16#1C#) => "FS ",
                Character'Val (16#1D#) => "GS ",
                Character'Val (16#1E#) => "RS ",
-               Character'Val (16#1F#) => "US ");
+               Character'Val (16#1F#) => "US "];
 
       subtype C1_Range is Character
         range Character'Val (16#7F#) .. Character'Val (16#9F#);
 
       C1 : constant array (C1_Range) of Cname :=
-              (Character'Val (16#7F#) => "DEL",
+              [Character'Val (16#7F#) => "DEL",
                Character'Val (16#80#) => "res",
                Character'Val (16#81#) => "res",
                Character'Val (16#82#) => "BPH",
@@ -117,7 +117,7 @@ package body System.Img_Char is
                Character'Val (16#9C#) => "ST ",
                Character'Val (16#9D#) => "OSC",
                Character'Val (16#9E#) => "PM ",
-               Character'Val (16#9F#) => "APC");
+               Character'Val (16#9F#) => "APC"];
 
    begin
       --  Control characters are represented by their names (RM 3.5(32))
index 0967403a9739c546ecd6876b1a63f70e3465b9a2..4dc490ca8a3598cd8511b03bb3dc09ed704f5e04 100644 (file)
@@ -42,26 +42,26 @@ package System.Powten_Flt is
    --  Largest power of ten exactly representable with a double Float
 
    Powten : constant array (0 .. Maxpow, 1 .. 2) of Float :=
-     (00 => (1.0E+00, 0.0),
-      01 => (1.0E+01, 0.0),
-      02 => (1.0E+02, 0.0),
-      03 => (1.0E+03, 0.0),
-      04 => (1.0E+04, 0.0),
-      05 => (1.0E+05, 0.0),
-      06 => (1.0E+06, 0.0),
-      07 => (1.0E+07, 0.0),
-      08 => (1.0E+08, 0.0),
-      09 => (1.0E+09, 0.0),
-      10 => (1.0E+10, 0.0),
-      11 => (1.0E+11, 1.0E+11 - Float'Machine (1.0E+11)),
-      12 => (1.0E+12, 1.0E+12 - Float'Machine (1.0E+12)),
-      13 => (1.0E+13, 1.0E+13 - Float'Machine (1.0E+13)),
-      14 => (1.0E+14, 1.0E+14 - Float'Machine (1.0E+14)),
-      15 => (1.0E+15, 1.0E+15 - Float'Machine (1.0E+15)),
-      16 => (1.0E+16, 1.0E+16 - Float'Machine (1.0E+16)),
-      17 => (1.0E+17, 1.0E+17 - Float'Machine (1.0E+17)),
-      18 => (1.0E+18, 1.0E+18 - Float'Machine (1.0E+18)),
-      19 => (1.0E+19, 1.0E+19 - Float'Machine (1.0E+19)),
-      20 => (1.0E+20, 1.0E+20 - Float'Machine (1.0E+20)));
+     [00 => [1.0E+00, 0.0],
+      01 => [1.0E+01, 0.0],
+      02 => [1.0E+02, 0.0],
+      03 => [1.0E+03, 0.0],
+      04 => [1.0E+04, 0.0],
+      05 => [1.0E+05, 0.0],
+      06 => [1.0E+06, 0.0],
+      07 => [1.0E+07, 0.0],
+      08 => [1.0E+08, 0.0],
+      09 => [1.0E+09, 0.0],
+      10 => [1.0E+10, 0.0],
+      11 => [1.0E+11, 1.0E+11 - Float'Machine (1.0E+11)],
+      12 => [1.0E+12, 1.0E+12 - Float'Machine (1.0E+12)],
+      13 => [1.0E+13, 1.0E+13 - Float'Machine (1.0E+13)],
+      14 => [1.0E+14, 1.0E+14 - Float'Machine (1.0E+14)],
+      15 => [1.0E+15, 1.0E+15 - Float'Machine (1.0E+15)],
+      16 => [1.0E+16, 1.0E+16 - Float'Machine (1.0E+16)],
+      17 => [1.0E+17, 1.0E+17 - Float'Machine (1.0E+17)],
+      18 => [1.0E+18, 1.0E+18 - Float'Machine (1.0E+18)],
+      19 => [1.0E+19, 1.0E+19 - Float'Machine (1.0E+19)],
+      20 => [1.0E+20, 1.0E+20 - Float'Machine (1.0E+20)]];
 
 end System.Powten_Flt;
index 7800f2ff57aa939ca7a3627b1e5d06a87fd6626e..0ae36ec3cd9025b6897deb11917dd442dc9d16db 100644 (file)
@@ -42,50 +42,50 @@ package System.Powten_LFlt is
    --  Largest power of ten exactly representable with a double Long_Float
 
    Powten : constant array (0 .. Maxpow, 1 .. 2) of Long_Float :=
-     (00 => (1.0E+00, 0.0),
-      01 => (1.0E+01, 0.0),
-      02 => (1.0E+02, 0.0),
-      03 => (1.0E+03, 0.0),
-      04 => (1.0E+04, 0.0),
-      05 => (1.0E+05, 0.0),
-      06 => (1.0E+06, 0.0),
-      07 => (1.0E+07, 0.0),
-      08 => (1.0E+08, 0.0),
-      09 => (1.0E+09, 0.0),
-      10 => (1.0E+10, 0.0),
-      11 => (1.0E+11, 0.0),
-      12 => (1.0E+12, 0.0),
-      13 => (1.0E+13, 0.0),
-      14 => (1.0E+14, 0.0),
-      15 => (1.0E+15, 0.0),
-      16 => (1.0E+16, 0.0),
-      17 => (1.0E+17, 0.0),
-      18 => (1.0E+18, 0.0),
-      19 => (1.0E+19, 0.0),
-      20 => (1.0E+20, 0.0),
-      21 => (1.0E+21, 0.0),
-      22 => (1.0E+22, 0.0),
-      23 => (1.0E+23, 1.0E+23 - Long_Float'Machine (1.0E+23)),
-      24 => (1.0E+24, 1.0E+24 - Long_Float'Machine (1.0E+24)),
-      25 => (1.0E+25, 1.0E+25 - Long_Float'Machine (1.0E+25)),
-      26 => (1.0E+26, 1.0E+26 - Long_Float'Machine (1.0E+26)),
-      27 => (1.0E+27, 1.0E+27 - Long_Float'Machine (1.0E+27)),
-      28 => (1.0E+28, 1.0E+28 - Long_Float'Machine (1.0E+28)),
-      29 => (1.0E+29, 1.0E+29 - Long_Float'Machine (1.0E+29)),
-      30 => (1.0E+30, 1.0E+30 - Long_Float'Machine (1.0E+30)),
-      31 => (1.0E+31, 1.0E+31 - Long_Float'Machine (1.0E+31)),
-      32 => (1.0E+32, 1.0E+32 - Long_Float'Machine (1.0E+32)),
-      33 => (1.0E+33, 1.0E+33 - Long_Float'Machine (1.0E+33)),
-      34 => (1.0E+34, 1.0E+34 - Long_Float'Machine (1.0E+34)),
-      35 => (1.0E+35, 1.0E+35 - Long_Float'Machine (1.0E+35)),
-      36 => (1.0E+36, 1.0E+36 - Long_Float'Machine (1.0E+36)),
-      37 => (1.0E+37, 1.0E+37 - Long_Float'Machine (1.0E+37)),
-      38 => (1.0E+38, 1.0E+38 - Long_Float'Machine (1.0E+38)),
-      39 => (1.0E+39, 1.0E+39 - Long_Float'Machine (1.0E+39)),
-      40 => (1.0E+40, 1.0E+40 - Long_Float'Machine (1.0E+40)),
-      41 => (1.0E+41, 1.0E+41 - Long_Float'Machine (1.0E+41)),
-      42 => (1.0E+42, 1.0E+42 - Long_Float'Machine (1.0E+42)),
-      43 => (1.0E+43, 1.0E+43 - Long_Float'Machine (1.0E+43)),
-      44 => (1.0E+44, 1.0E+44 - Long_Float'Machine (1.0E+44)));
+     [00 => [1.0E+00, 0.0],
+      01 => [1.0E+01, 0.0],
+      02 => [1.0E+02, 0.0],
+      03 => [1.0E+03, 0.0],
+      04 => [1.0E+04, 0.0],
+      05 => [1.0E+05, 0.0],
+      06 => [1.0E+06, 0.0],
+      07 => [1.0E+07, 0.0],
+      08 => [1.0E+08, 0.0],
+      09 => [1.0E+09, 0.0],
+      10 => [1.0E+10, 0.0],
+      11 => [1.0E+11, 0.0],
+      12 => [1.0E+12, 0.0],
+      13 => [1.0E+13, 0.0],
+      14 => [1.0E+14, 0.0],
+      15 => [1.0E+15, 0.0],
+      16 => [1.0E+16, 0.0],
+      17 => [1.0E+17, 0.0],
+      18 => [1.0E+18, 0.0],
+      19 => [1.0E+19, 0.0],
+      20 => [1.0E+20, 0.0],
+      21 => [1.0E+21, 0.0],
+      22 => [1.0E+22, 0.0],
+      23 => [1.0E+23, 1.0E+23 - Long_Float'Machine (1.0E+23)],
+      24 => [1.0E+24, 1.0E+24 - Long_Float'Machine (1.0E+24)],
+      25 => [1.0E+25, 1.0E+25 - Long_Float'Machine (1.0E+25)],
+      26 => [1.0E+26, 1.0E+26 - Long_Float'Machine (1.0E+26)],
+      27 => [1.0E+27, 1.0E+27 - Long_Float'Machine (1.0E+27)],
+      28 => [1.0E+28, 1.0E+28 - Long_Float'Machine (1.0E+28)],
+      29 => [1.0E+29, 1.0E+29 - Long_Float'Machine (1.0E+29)],
+      30 => [1.0E+30, 1.0E+30 - Long_Float'Machine (1.0E+30)],
+      31 => [1.0E+31, 1.0E+31 - Long_Float'Machine (1.0E+31)],
+      32 => [1.0E+32, 1.0E+32 - Long_Float'Machine (1.0E+32)],
+      33 => [1.0E+33, 1.0E+33 - Long_Float'Machine (1.0E+33)],
+      34 => [1.0E+34, 1.0E+34 - Long_Float'Machine (1.0E+34)],
+      35 => [1.0E+35, 1.0E+35 - Long_Float'Machine (1.0E+35)],
+      36 => [1.0E+36, 1.0E+36 - Long_Float'Machine (1.0E+36)],
+      37 => [1.0E+37, 1.0E+37 - Long_Float'Machine (1.0E+37)],
+      38 => [1.0E+38, 1.0E+38 - Long_Float'Machine (1.0E+38)],
+      39 => [1.0E+39, 1.0E+39 - Long_Float'Machine (1.0E+39)],
+      40 => [1.0E+40, 1.0E+40 - Long_Float'Machine (1.0E+40)],
+      41 => [1.0E+41, 1.0E+41 - Long_Float'Machine (1.0E+41)],
+      42 => [1.0E+42, 1.0E+42 - Long_Float'Machine (1.0E+42)],
+      43 => [1.0E+43, 1.0E+43 - Long_Float'Machine (1.0E+43)],
+      44 => [1.0E+44, 1.0E+44 - Long_Float'Machine (1.0E+44)]];
 
 end System.Powten_LFlt;
index b1f8ae995acc9a9a0685537137708b1745615f6c..eaba6c14b0e5b76e0aaab1e5ba54f721cec24364 100644 (file)
@@ -44,60 +44,60 @@ package System.Powten_LLF is
    --  Largest power of ten exactly representable with a double Long_Long_Float
 
    Powten : constant array (0 .. 54, 1 .. 2) of Long_Long_Float :=
-     (00 => (1.0E+00, 0.0),
-      01 => (1.0E+01, 0.0),
-      02 => (1.0E+02, 0.0),
-      03 => (1.0E+03, 0.0),
-      04 => (1.0E+04, 0.0),
-      05 => (1.0E+05, 0.0),
-      06 => (1.0E+06, 0.0),
-      07 => (1.0E+07, 0.0),
-      08 => (1.0E+08, 0.0),
-      09 => (1.0E+09, 0.0),
-      10 => (1.0E+10, 0.0),
-      11 => (1.0E+11, 0.0),
-      12 => (1.0E+12, 0.0),
-      13 => (1.0E+13, 0.0),
-      14 => (1.0E+14, 0.0),
-      15 => (1.0E+15, 0.0),
-      16 => (1.0E+16, 0.0),
-      17 => (1.0E+17, 0.0),
-      18 => (1.0E+18, 0.0),
-      19 => (1.0E+19, 0.0),
-      20 => (1.0E+20, 0.0),
-      21 => (1.0E+21, 0.0),
-      22 => (1.0E+22, 0.0),
-      23 => (1.0E+23, 1.0E+23 - Long_Long_Float'Machine (1.0E+23)),
-      24 => (1.0E+24, 1.0E+24 - Long_Long_Float'Machine (1.0E+24)),
-      25 => (1.0E+25, 1.0E+25 - Long_Long_Float'Machine (1.0E+25)),
-      26 => (1.0E+26, 1.0E+26 - Long_Long_Float'Machine (1.0E+26)),
-      27 => (1.0E+27, 1.0E+27 - Long_Long_Float'Machine (1.0E+27)),
-      28 => (1.0E+28, 1.0E+28 - Long_Long_Float'Machine (1.0E+28)),
-      29 => (1.0E+29, 1.0E+29 - Long_Long_Float'Machine (1.0E+29)),
-      30 => (1.0E+30, 1.0E+30 - Long_Long_Float'Machine (1.0E+30)),
-      31 => (1.0E+31, 1.0E+31 - Long_Long_Float'Machine (1.0E+31)),
-      32 => (1.0E+32, 1.0E+32 - Long_Long_Float'Machine (1.0E+32)),
-      33 => (1.0E+33, 1.0E+33 - Long_Long_Float'Machine (1.0E+33)),
-      34 => (1.0E+34, 1.0E+34 - Long_Long_Float'Machine (1.0E+34)),
-      35 => (1.0E+35, 1.0E+35 - Long_Long_Float'Machine (1.0E+35)),
-      36 => (1.0E+36, 1.0E+36 - Long_Long_Float'Machine (1.0E+36)),
-      37 => (1.0E+37, 1.0E+37 - Long_Long_Float'Machine (1.0E+37)),
-      38 => (1.0E+38, 1.0E+38 - Long_Long_Float'Machine (1.0E+38)),
-      39 => (1.0E+39, 1.0E+39 - Long_Long_Float'Machine (1.0E+39)),
-      40 => (1.0E+40, 1.0E+40 - Long_Long_Float'Machine (1.0E+40)),
-      41 => (1.0E+41, 1.0E+41 - Long_Long_Float'Machine (1.0E+41)),
-      42 => (1.0E+42, 1.0E+42 - Long_Long_Float'Machine (1.0E+42)),
-      43 => (1.0E+43, 1.0E+43 - Long_Long_Float'Machine (1.0E+43)),
-      44 => (1.0E+44, 1.0E+44 - Long_Long_Float'Machine (1.0E+44)),
-      45 => (1.0E+45, 1.0E+45 - Long_Long_Float'Machine (1.0E+45)),
-      46 => (1.0E+46, 1.0E+46 - Long_Long_Float'Machine (1.0E+46)),
-      47 => (1.0E+47, 1.0E+47 - Long_Long_Float'Machine (1.0E+47)),
-      48 => (1.0E+48, 1.0E+48 - Long_Long_Float'Machine (1.0E+48)),
-      49 => (1.0E+49, 1.0E+49 - Long_Long_Float'Machine (1.0E+49)),
-      50 => (1.0E+50, 1.0E+50 - Long_Long_Float'Machine (1.0E+50)),
-      51 => (1.0E+51, 1.0E+51 - Long_Long_Float'Machine (1.0E+51)),
-      52 => (1.0E+52, 1.0E+52 - Long_Long_Float'Machine (1.0E+52)),
-      53 => (1.0E+53, 1.0E+53 - Long_Long_Float'Machine (1.0E+53)),
-      54 => (1.0E+54, 1.0E+54 - Long_Long_Float'Machine (1.0E+54)));
+     [00 => [1.0E+00, 0.0],
+      01 => [1.0E+01, 0.0],
+      02 => [1.0E+02, 0.0],
+      03 => [1.0E+03, 0.0],
+      04 => [1.0E+04, 0.0],
+      05 => [1.0E+05, 0.0],
+      06 => [1.0E+06, 0.0],
+      07 => [1.0E+07, 0.0],
+      08 => [1.0E+08, 0.0],
+      09 => [1.0E+09, 0.0],
+      10 => [1.0E+10, 0.0],
+      11 => [1.0E+11, 0.0],
+      12 => [1.0E+12, 0.0],
+      13 => [1.0E+13, 0.0],
+      14 => [1.0E+14, 0.0],
+      15 => [1.0E+15, 0.0],
+      16 => [1.0E+16, 0.0],
+      17 => [1.0E+17, 0.0],
+      18 => [1.0E+18, 0.0],
+      19 => [1.0E+19, 0.0],
+      20 => [1.0E+20, 0.0],
+      21 => [1.0E+21, 0.0],
+      22 => [1.0E+22, 0.0],
+      23 => [1.0E+23, 1.0E+23 - Long_Long_Float'Machine (1.0E+23)],
+      24 => [1.0E+24, 1.0E+24 - Long_Long_Float'Machine (1.0E+24)],
+      25 => [1.0E+25, 1.0E+25 - Long_Long_Float'Machine (1.0E+25)],
+      26 => [1.0E+26, 1.0E+26 - Long_Long_Float'Machine (1.0E+26)],
+      27 => [1.0E+27, 1.0E+27 - Long_Long_Float'Machine (1.0E+27)],
+      28 => [1.0E+28, 1.0E+28 - Long_Long_Float'Machine (1.0E+28)],
+      29 => [1.0E+29, 1.0E+29 - Long_Long_Float'Machine (1.0E+29)],
+      30 => [1.0E+30, 1.0E+30 - Long_Long_Float'Machine (1.0E+30)],
+      31 => [1.0E+31, 1.0E+31 - Long_Long_Float'Machine (1.0E+31)],
+      32 => [1.0E+32, 1.0E+32 - Long_Long_Float'Machine (1.0E+32)],
+      33 => [1.0E+33, 1.0E+33 - Long_Long_Float'Machine (1.0E+33)],
+      34 => [1.0E+34, 1.0E+34 - Long_Long_Float'Machine (1.0E+34)],
+      35 => [1.0E+35, 1.0E+35 - Long_Long_Float'Machine (1.0E+35)],
+      36 => [1.0E+36, 1.0E+36 - Long_Long_Float'Machine (1.0E+36)],
+      37 => [1.0E+37, 1.0E+37 - Long_Long_Float'Machine (1.0E+37)],
+      38 => [1.0E+38, 1.0E+38 - Long_Long_Float'Machine (1.0E+38)],
+      39 => [1.0E+39, 1.0E+39 - Long_Long_Float'Machine (1.0E+39)],
+      40 => [1.0E+40, 1.0E+40 - Long_Long_Float'Machine (1.0E+40)],
+      41 => [1.0E+41, 1.0E+41 - Long_Long_Float'Machine (1.0E+41)],
+      42 => [1.0E+42, 1.0E+42 - Long_Long_Float'Machine (1.0E+42)],
+      43 => [1.0E+43, 1.0E+43 - Long_Long_Float'Machine (1.0E+43)],
+      44 => [1.0E+44, 1.0E+44 - Long_Long_Float'Machine (1.0E+44)],
+      45 => [1.0E+45, 1.0E+45 - Long_Long_Float'Machine (1.0E+45)],
+      46 => [1.0E+46, 1.0E+46 - Long_Long_Float'Machine (1.0E+46)],
+      47 => [1.0E+47, 1.0E+47 - Long_Long_Float'Machine (1.0E+47)],
+      48 => [1.0E+48, 1.0E+48 - Long_Long_Float'Machine (1.0E+48)],
+      49 => [1.0E+49, 1.0E+49 - Long_Long_Float'Machine (1.0E+49)],
+      50 => [1.0E+50, 1.0E+50 - Long_Long_Float'Machine (1.0E+50)],
+      51 => [1.0E+51, 1.0E+51 - Long_Long_Float'Machine (1.0E+51)],
+      52 => [1.0E+52, 1.0E+52 - Long_Long_Float'Machine (1.0E+52)],
+      53 => [1.0E+53, 1.0E+53 - Long_Long_Float'Machine (1.0E+53)],
+      54 => [1.0E+54, 1.0E+54 - Long_Long_Float'Machine (1.0E+54)]];
 
 end System.Powten_LLF;
index 92a91a602e2e08bfb05d68cd482d4ee0c26b797e..147cc9ac1a581fc8d11d34964ea481e21927b489 100644 (file)
@@ -109,7 +109,7 @@ is
    Upper_Mask : constant := 2**31;
 
    Matrix_A   : constant array (State_Val range 0 .. 1) of State_Val
-     := (0, 16#9908b0df#);
+     := [0, 16#9908b0df#];
    --  The twist transformation is represented by a matrix of the form
    --
    --               [  0    I(31) ]
@@ -275,16 +275,16 @@ is
 
             Trailing_Ones : constant array (Unsigned_32 range 0 .. 15)
               of Bit_Count :=
-                  (2#00000# => 0, 2#00001# => 1, 2#00010# => 0, 2#00011# => 2,
+                  [2#00000# => 0, 2#00001# => 1, 2#00010# => 0, 2#00011# => 2,
                    2#00100# => 0, 2#00101# => 1, 2#00110# => 0, 2#00111# => 3,
                    2#01000# => 0, 2#01001# => 1, 2#01010# => 0, 2#01011# => 2,
-                   2#01100# => 0, 2#01101# => 1, 2#01110# => 0, 2#01111# => 4);
+                   2#01100# => 0, 2#01101# => 1, 2#01110# => 0, 2#01111# => 4];
 
             Pow_Tab : constant array (Bit_Count range 0 .. 3) of Real
-              := (0 => 2.0**(0 - T'Machine_Mantissa),
+              := [0 => 2.0**(0 - T'Machine_Mantissa),
                   1 => 2.0**(-1 - T'Machine_Mantissa),
                   2 => 2.0**(-2 - T'Machine_Mantissa),
-                  3 => 2.0**(-3 - T'Machine_Mantissa));
+                  3 => 2.0**(-3 - T'Machine_Mantissa)];
 
             Extra_Bits : constant Natural :=
                          (Unsigned'Size - T'Machine_Mantissa + 1);
@@ -662,7 +662,7 @@ is
       Result : Image_String;
 
    begin
-      Result := (others => ' ');
+      Result := [others => ' '];
 
       for J in Of_State'Range loop
          Insert_Image (Result, J, Of_State (J));
@@ -675,7 +675,7 @@ is
       Result : Image_String;
 
    begin
-      Result := (others => ' ');
+      Result := [others => ' '];
       for J in 0 .. N - 1 loop
          Insert_Image (Result, J, Gen.S ((J + Gen.I) mod N));
       end loop;
index 99ed57daadd4f68cd70959f3c5f849d034a10803..24c8d7f4d0c8103a7585d81ee25549ce4dcf88b9 100644 (file)
@@ -157,7 +157,7 @@ private
       Writable  : Writable_Access (Generator'Access);
       --  This self reference allows functions to modify Generator arguments
 
-      S : State := (others => 0);
+      S : State := [others => 0];
       --  The shift register, a circular buffer
 
       I : Integer := N;
index 8f1940a854456e83fdf84b12125fceb0531b5fa4..bb21ef76212ff54c436fd3f9509d16aee0b1590e 100644 (file)
@@ -124,7 +124,7 @@ package body System.Regexp is
       --  The pattern which is really compiled (when the pattern is case
       --  insensitive, we convert this string to lower-cases).
 
-      Map : Mapping := (others => 0);
+      Map : Mapping := [others => 0];
       --  Mapping between characters and columns in the tables
 
       Alphabet_Size : Column_Index := 0;
@@ -1103,7 +1103,7 @@ package body System.Regexp is
       --  Start of processing for Create_Primary_Table
 
       begin
-         Table.all := (others => (others => 0));
+         Table.all := [others => [others => 0]];
          Create_Simple (S'First, S'Last, Start_State, End_State);
          Num_States := Current_State;
       end Create_Primary_Table;
@@ -1372,7 +1372,7 @@ package body System.Regexp is
       --  Start of processing for Create_Primary_Table_Glob
 
       begin
-         Table.all := (others => (others => 0));
+         Table.all := [others => [others => 0]];
          Create_Simple (S'First, S'Last, Start_State, End_State);
          Num_States := Current_State;
       end Create_Primary_Table_Glob;
@@ -1392,7 +1392,7 @@ package body System.Regexp is
          pragma Pack (Meta_State);
          --  Whether a state from first_table belongs to a metastate.
 
-         No_States : constant Meta_State := (others => False);
+         No_States : constant Meta_State := [others => False];
 
          type Meta_States_Array is array (State_Index range <>) of Meta_State;
          type Meta_States_List is access all Meta_States_Array;
@@ -1444,25 +1444,25 @@ package body System.Regexp is
             if Meta_States = null then
                Meta_States := new Meta_States_Array
                   (1 .. State_Index'Max (Last_Index, Meta) + 1);
-               Meta_States (Meta_States'Range) := (others => No_States);
+               Meta_States (Meta_States'Range) := [others => No_States];
 
                Table := new Meta_States_Transition_Arr
                   (1 .. State_Index'Max (Last_Index, Meta) + 1);
-               Table.all := (others => (others => 0));
+               Table.all := [others => [others => 0]];
 
             elsif Meta > Meta_States'Last then
                Meta_States := new Meta_States_Array
                   (1 .. State_Index'Max (2 * Tmp'Last, Meta));
                Meta_States (Tmp'Range) := Tmp.all;
                Meta_States (Tmp'Last + 1 .. Meta_States'Last) :=
-                  (others => No_States);
+                  [others => No_States];
                Unchecked_Free (Tmp);
 
                Table := new Meta_States_Transition_Arr
                   (1 .. State_Index'Max (2 * Tmp2'Last, Meta) + 1);
                Table (Tmp2'Range) := Tmp2.all;
                Table (Tmp2'Last + 1 .. Table'Last) :=
-                  (others => (others => 0));
+                  [others => [others => 0]];
                Unchecked_Free (Tmp2);
             end if;
          end Ensure_Meta_State;
@@ -1595,9 +1595,9 @@ package body System.Regexp is
                  R => new Regexp_Value'
                       (Alphabet_Size => 0,
                        Num_States    => 1,
-                       Map           => (others => 0),
-                       States        => (others => (others => 1)),
-                       Is_Final      => (others => True),
+                       Map           => [others => 0],
+                       States        => [others => [others => 1]],
+                       Is_Final      => [others => True],
                        Case_Sensitive => True));
       end if;
 
@@ -1726,7 +1726,7 @@ package body System.Regexp is
          New_Columns := Table'Last (2) * (Column / Table'Last (2) + 1);
          New_Table := new Regexp_Array (Table'First (1) .. New_Lines,
                                         Table'First (2) .. New_Columns);
-         New_Table.all := (others => (others => 0));
+         New_Table.all := [others => [others => 0]];
 
          for J in Table'Range (1) loop
             for K in Table'Range (2) loop
index b40f682859de8c7d28a08bc26ab1cab4459768a0..00833bb1b0b71f4b3c238e6e3374157c60bebc74 100644 (file)
@@ -199,7 +199,7 @@ package body System.Regpat is
 
    type Bit_Conversion_Array is array (Class_Byte range 0 .. 7) of Class_Byte;
    Bit_Conversion : constant Bit_Conversion_Array :=
-                      (1, 2, 4, 8, 16, 32, 64, 128);
+                      [1, 2, 4, 8, 16, 32, 64, 128];
 
    type Std_Class is (ANYOF_NONE,
                       ANYOF_ALNUM,   --  Alphanumeric class [a-zA-Z0-9]
@@ -2111,9 +2111,9 @@ package body System.Regpat is
             declare
                Point   : constant String := Pointer'Image (Index);
             begin
-               Put ((1 .. 4 - Point'Length => ' ')
+               Put ([1 .. 4 - Point'Length => ' ']
                     & Point & ":"
-                    & (1 .. Local_Indent * 2 => ' ') & Opcode'Image (Op));
+                    & [1 .. Local_Indent * 2 => ' '] & Opcode'Image (Op));
             end;
 
             --  Print the parenthesis number
@@ -2506,11 +2506,11 @@ package body System.Regpat is
 
       begin
          if Prefix then
-            Put ((1 .. 5 - Pos'Length => ' '));
+            Put ([1 .. 5 - Pos'Length => ' ']);
             Put (Pos & " <"
                  & Data (Input_Pos
                      .. Integer'Min (Last_In_Data, Input_Pos + Length - 1)));
-            Put ((1 .. Length - 1 - Last_In_Data + Input_Pos => ' '));
+            Put ([1 .. Length - 1 - Last_In_Data + Input_Pos => ' ']);
             Put ("> |");
 
          else
@@ -2527,7 +2527,7 @@ package body System.Regpat is
       procedure Dump_Error (Msg : String) is
       begin
          Put ("                   |     ");
-         Put ((1 .. Dump_Indent * 2 => ' '));
+         Put ([1 .. Dump_Indent * 2 => ' ']);
          Put_Line (Msg);
       end Dump_Error;
 
@@ -3381,7 +3381,7 @@ package body System.Regpat is
       begin
          Input_Pos  := Pos;
          Last_Paren := 0;
-         Matches_Full := (others => No_Match);
+         Matches_Full := [others => No_Match];
 
          if Match (Program_First) then
             Matches_Full (0) := (Pos, Input_Pos - 1);
@@ -3397,7 +3397,7 @@ package body System.Regpat is
       --  Do we have the regexp Never_Match?
 
       if Self.Size = 0 then
-         Matches := (others => No_Match);
+         Matches := [others => No_Match];
          return;
       end if;
 
@@ -3420,7 +3420,7 @@ package body System.Regpat is
             end loop;
 
             if Next_Try = 0 then
-               Matches := (others => No_Match);
+               Matches := [others => No_Match];
                return;                  -- Not present
             end if;
          end;
@@ -3740,7 +3740,7 @@ package body System.Regpat is
 
    procedure Reset_Class (Bitmap : out Character_Class) is
    begin
-      Bitmap := (others => 0);
+      Bitmap := [others => 0];
    end Reset_Class;
 
    ------------------
index 8fac30a0e01d3ed2c723e9179bb05fdde0449f59..637e76c3577437d0b454e4ebcc3111404b9af7f1 100644 (file)
@@ -639,10 +639,10 @@ private
       Paren_Count      : Natural      := 0;          --  # paren groups
       Flags            : Regexp_Flags := No_Flags;
       Program          : Program_Data (Program_First .. Size) :=
-                           (others => ASCII.NUL);
+                           [others => ASCII.NUL];
    end record;
 
    Never_Match : constant Pattern_Matcher :=
-      (0, ASCII.NUL, False, 0, 0, 0, No_Flags, (others => ASCII.NUL));
+      (0, ASCII.NUL, False, 0, 0, 0, No_Flags, [others => ASCII.NUL]);
 
 end System.Regpat;
index 7bb5696a2cfa23038546cd8a587da8555f8ef118..2276fccafe745784f2e41c38d48dc4f49436574f 100644 (file)
@@ -180,7 +180,7 @@ package body System.Scalar_Values is
          IV_Ilf := To_ByteLF (IS_Iu8);
 
          if EFloat then
-            IV_Ill := (0, 0, 0, 0, 0, 0, 0, 16#C0#, 16#FF#, 16#FF#, 0, 0);
+            IV_Ill := [0, 0, 0, 0, 0, 0, 0, 16#C0#, 16#FF#, 16#FF#, 0, 0];
          end if;
 
       --  LO (Low values)
@@ -209,7 +209,7 @@ package body System.Scalar_Values is
          IV_Ilf := To_ByteLF (16#FFF0_0000_0000_0000#);
 
          if EFloat then
-            IV_Ill := (0, 0, 0, 0, 0, 0, 0, 16#80#, 16#FF#, 16#FF#, 0, 0);
+            IV_Ill := [0, 0, 0, 0, 0, 0, 0, 16#80#, 16#FF#, 16#FF#, 0, 0];
          end if;
 
       --  HI (High values)
@@ -238,7 +238,7 @@ package body System.Scalar_Values is
          IV_Ilf := To_ByteLF (16#7FF0_0000_0000_0000#);
 
          if EFloat then
-            IV_Ill := (0, 0, 0, 0, 0, 0, 0, 16#80#, 16#FF#, 16#7F#, 0, 0);
+            IV_Ill := [0, 0, 0, 0, 0, 0, 0, 16#80#, 16#FF#, 16#7F#, 0, 0];
          end if;
 
       --  -Shh (hex byte)
@@ -281,7 +281,7 @@ package body System.Scalar_Values is
          IV_Ilf := To_ByteLF (IS_Is8);
 
          if EFloat then
-            IV_Ill := (B, B, B, B, B, B, B, B, B, B, B, B);
+            IV_Ill := [B, B, B, B, B, B, B, B, B, B, B, B];
          end if;
       end if;
 
index af88f7d044ad597a0ce44ee2ffe110de4317f1c8..4de49a9a04d406fc206f21f4d3b9e7bc6667c1ef 100644 (file)
@@ -72,40 +72,40 @@ package body System.Stream_Attributes.XDR is
 
    type Precision is (Single, Double, Quadruple);
 
-   Fields : constant array (Precision) of Field_Type := (
+   Fields : constant array (Precision) of Field_Type := [
 
                --  Single precision
 
-              (E_Size  => 8,
+              [E_Size  => 8,
                E_Bias  => 127,
                F_Size  => 23,
                E_Last  => 2 ** 8 - 1,
                F_Mask  => 16#7F#,                  --  2 ** 7 - 1,
                E_Bytes => 2,
                F_Bytes => 3,
-               F_Bits  => 23 mod US),
+               F_Bits  => 23 mod US],
 
                --  Double precision
 
-              (E_Size  => 11,
+              [E_Size  => 11,
                E_Bias  => 1023,
                F_Size  => 52,
                E_Last  => 2 ** 11 - 1,
                F_Mask  => 16#0F#,                  --  2 ** 4 - 1,
                E_Bytes => 2,
                F_Bytes => 7,
-               F_Bits  => 52 mod US),
+               F_Bits  => 52 mod US],
 
                --  Quadruple precision
 
-              (E_Size  => 15,
+              [E_Size  => 15,
                E_Bias  => 16383,
                F_Size  => 112,
                E_Last  => 2 ** 8 - 1,
                F_Mask  => 16#FF#,                  --  2 ** 8 - 1,
                E_Bytes => 2,
                F_Bytes => 14,
-               F_Bits  => 112 mod US));
+               F_Bits  => 112 mod US]];
 
    --  The representation of all items requires a multiple of four bytes
    --  (or 32 bits) of data. The bytes are numbered 0 through n-1. The bytes
@@ -1244,7 +1244,7 @@ package body System.Stream_Attributes.XDR is
       Is_Positive : Boolean;
       E           : Integer;
       F           : Float;
-      S           : SEA (1 .. F_L) := (others => 0);
+      S           : SEA (1 .. F_L) := [others => 0];
 
    begin
       if not Item'Valid then
@@ -1390,7 +1390,7 @@ package body System.Stream_Attributes.XDR is
       Is_Positive : Boolean;
       E           : Integer;
       F           : Long_Float;
-      S           : SEA (1 .. LF_L) := (others => 0);
+      S           : SEA (1 .. LF_L) := [others => 0];
 
    begin
       if not Item'Valid then
@@ -1519,7 +1519,7 @@ package body System.Stream_Attributes.XDR is
       Is_Positive : Boolean;
       E           : Integer;
       F           : Long_Long_Float := Item;
-      S           : SEA (1 .. LLF_L) := (others => 0);
+      S           : SEA (1 .. LLF_L) := [others => 0];
 
    begin
       if not Item'Valid then
@@ -1737,7 +1737,7 @@ package body System.Stream_Attributes.XDR is
       Is_Positive : Boolean;
       E           : Integer;
       F           : Short_Float;
-      S           : SEA (1 .. SF_L) := (others => 0);
+      S           : SEA (1 .. SF_L) := [others => 0];
 
    begin
       if not Item'Valid then
index 8bd6c5b52c260474f20c5ffd050aab27ee5b6a70..cd34ab67ae2f52375a04e7b236a4ab0d605ec15c 100644 (file)
@@ -127,10 +127,10 @@ package body System.Stack_Usage is
 
       Result_Array := new Result_Array_Type (1 .. Buffer_Size);
       Result_Array.all :=
-        (others =>
-           (Task_Name   => (others => ASCII.NUL),
+        [others =>
+           [Task_Name   => [others => ASCII.NUL],
             Value       => 0,
-            Stack_Size  => 0));
+            Stack_Size  => 0]];
 
       --  Set the Is_Enabled flag to true, so that the task wrapper knows that
       --  it has to handle dynamic stack analysis
@@ -282,7 +282,7 @@ package body System.Stack_Usage is
       Analyzer.Pattern_Size  := Pattern_Size;
       Analyzer.Pattern       := Pattern;
       Analyzer.Result_Id     := Next_Id;
-      Analyzer.Task_Name     := (others => ' ');
+      Analyzer.Task_Name     := [others => ' '];
 
       --  Compute the task name, and truncate if bigger than Task_Name_Length
 
@@ -455,12 +455,12 @@ package body System.Stack_Usage is
             Stack_Size_Blanks  : constant
                                    String (1 .. Max_Stack_Size_Len -
                                                   Stack_Size_Str'Length) :=
-                                      (others => ' ');
+                                      [others => ' '];
 
             Stack_Usage_Blanks : constant
                                    String (1 .. Max_Actual_Use_Len -
                                                   Actual_Size_Str'Length) :=
-                                      (others => ' ');
+                                      [others => ' '];
 
          begin
             if Stack_Size_Str'Length > Max_Stack_Size_Len then
index 1644d85f88cb83b2d10c04671d0f95157caa062b..f57669267c2c93cac3c8146ac6dee1463c5601fa 100644 (file)
@@ -92,7 +92,7 @@ package body System.String_Ops is
    function Str_Concat_SC (X : String; Y : Character) return String is
    begin
       if X'Length = 0 then
-         return (1 => Y);
+         return [Y];
 
       else
          declare
index bc5465cf4b9f2506ef3de184af5d7451702234f3..b37383ab203b95420832e5a2a107504c21bebf48 100644 (file)
@@ -63,19 +63,19 @@ package body System.Val_Real is
    --  index N is the largest K such that N**K <= Num'Last.
 
    Maxexp32 : constant array (Base_T) of Positive :=
-     (2  => 127, 3 => 80,  4 => 63,  5 => 55,  6 => 49,
+     [2  => 127, 3 => 80,  4 => 63,  5 => 55,  6 => 49,
       7  => 45,  8 => 42,  9 => 40, 10 => 38, 11 => 37,
-      12 => 35, 13 => 34, 14 => 33, 15 => 32, 16 => 31);
+      12 => 35, 13 => 34, 14 => 33, 15 => 32, 16 => 31];
 
    Maxexp64 : constant array (Base_T) of Positive :=
-     (2  => 1023, 3 => 646,  4 => 511,  5 => 441,  6 => 396,
+     [2  => 1023, 3 => 646,  4 => 511,  5 => 441,  6 => 396,
       7  => 364,  8 => 341,  9 => 323, 10 => 308, 11 => 296,
-      12 => 285, 13 => 276, 14 => 268, 15 => 262, 16 => 255);
+      12 => 285, 13 => 276, 14 => 268, 15 => 262, 16 => 255];
 
    Maxexp80 : constant array (Base_T) of Positive :=
-     (2  => 16383, 3 => 10337, 4 => 8191,  5 => 7056,  6 => 6338,
+     [2  => 16383, 3 => 10337, 4 => 8191,  5 => 7056,  6 => 6338,
       7  => 5836,  8 => 5461,  9 => 5168, 10 => 4932, 11 => 4736,
-      12 => 4570, 13 => 4427, 14 => 4303, 15 => 4193, 16 => 4095);
+      12 => 4570, 13 => 4427, 14 => 4303, 15 => 4193, 16 => 4095];
 
    package Double_Real is new System.Double_Real (Num);
    use type Double_Real.Double_T;
index 3e82260020843c5334c4ac4b74c22bc288a46e4f..897f59556b1e0c9f6d603a0ea749283af3640e57 100644 (file)
@@ -167,12 +167,12 @@ package System.WCh_Con is
    --  no ambiguity in Ada sources, since the above sequences are illegal Ada).
 
    WC_Encoding_Letters : constant array (WC_Encoding_Method) of Character :=
-     (WCEM_Hex       => 'h',
+     [WCEM_Hex       => 'h',
       WCEM_Upper     => 'u',
       WCEM_Shift_JIS => 's',
       WCEM_EUC       => 'e',
       WCEM_UTF8      => '8',
-      WCEM_Brackets  => 'b');
+      WCEM_Brackets  => 'b'];
    --  Letters used for selection of wide character encoding method in the
    --  compiler options (-gnatW? switch) and for Wide_Text_IO (WCEM parameter
    --  in the form string).
@@ -191,12 +191,12 @@ package System.WCh_Con is
    --  or wide wide character sequence for any of the active encoding methods.
 
    WC_Longest_Sequences : constant array (WC_Encoding_Method) of Natural :=
-     (WCEM_Hex       => 5,
+     [WCEM_Hex       => 5,
       WCEM_Upper     => 2,
       WCEM_Shift_JIS => 2,
       WCEM_EUC       => 2,
       WCEM_UTF8      => 6,
-      WCEM_Brackets  => 12);
+      WCEM_Brackets  => 12];
    --  The longest number of characters that can be used for a wide character
    --  or wide wide character sequence using the given encoding method.
 
index aa49bff5318145f31d985bb00b9263d4a358fc94..d985003751f072e0a6fcbe248b05abf47fb27e93 100644 (file)
@@ -1694,6 +1694,10 @@ package body Ch4 is
                end if;
             end if;
          when Tok_Left_Paren =>
+            if Nkind (Aggregate_Node) = N_Aggregate then
+               Set_Is_Parenthesis_Aggregate (Aggregate_Node);
+            end if;
+
             T_Right_Paren;
          when others => raise Program_Error;
       end case;
index fd184b591d27c1ab132b60bb30c72a6020374c29..33a726705be14bb4a2ca1fd76b03b10025a4b8e1 100644 (file)
@@ -1425,11 +1425,11 @@ package body Scng is
 
          when '[' =>
 
-            --  [] under -gnatX is an aggregate notation and the special
+            --  [] under -gnat2022 is an aggregate notation and the special
             --  wide character notation becomes unsupported since the two
             --  are ambiguous.
 
-            if Extensions_Allowed then
+            if Ada_Version >= Ada_2022 then
                Scan_Ptr := Scan_Ptr + 1;
                Token := Tok_Left_Bracket;
                return;
index 5f9865e365f65781b99cd35dea3a7f1ebce9b1e5..0d4af65e8a655f17811f3169e2a0718bc94c859b 100644 (file)
@@ -248,7 +248,7 @@ package body Sem_Aggr is
    --  The procedure works by recursively checking each nested aggregate.
    --  Specifically, after checking a sub-aggregate nested at the i-th level
    --  we recursively check all the subaggregates at the i+1-st level (if any).
-   --  Note that for aggregates analysis and resolution go hand in hand.
+   --  Note that aggregates analysis and resolution go hand in hand.
    --  Aggregate analysis has been delayed up to here and it is done while
    --  resolving the aggregate.
    --
@@ -918,6 +918,12 @@ package body Sem_Aggr is
         and then Ekind (Typ) /= E_Record_Type
         and then Ada_Version >= Ada_2022
       then
+         --  Check for Ada 2022 and () aggregate.
+
+         if not Is_Homogeneous_Aggregate (N) then
+            Error_Msg_N ("container aggregate must use '['], not ()", N);
+         end if;
+
          Resolve_Container_Aggregate (N, Typ);
 
       elsif Is_Record_Type (Typ) then
@@ -1792,6 +1798,21 @@ package body Sem_Aggr is
          return False;
       end if;
 
+      --  Disable the warning for GNAT Mode to allow for easier transition.
+
+      if Ada_Version >= Ada_2022
+        and then Warn_On_Obsolescent_Feature
+        and then not GNAT_Mode
+        and then not Is_Homogeneous_Aggregate (N)
+        and then not Is_Enum_Array_Aggregate (N)
+        and then Is_Parenthesis_Aggregate (N)
+        and then Nkind (Parent (N)) /= N_Qualified_Expression
+      then
+         Error_Msg_N
+           ("?j?array aggregate using () is an" &
+              " obsolescent syntax, use '['] instead", N);
+      end if;
+
       --  STEP 1: make sure the aggregate is correctly formatted
 
       if Present (Component_Associations (N)) then
index 2878fce80ffc74171c345f797cefe14872d5dad2..9ab2528fd443e13fc36614121c8b7080b25fc35e 100644 (file)
@@ -372,7 +372,7 @@ package Sem_Util is
    procedure Check_Ambiguous_Aggregate (Call : Node_Id);
    --  Additional information on an ambiguous call in Ada_2022 when a
    --  subprogram call has an actual that is an aggregate, and the
-   --  presence of container aggregates (or types with the correwponding
+   --  presence of container aggregates (or types with the corresponding
    --  aspect)  provides an additional interpretation. Message indicates
    --  that an aggregate actual should carry a type qualification.