aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada
AgeCommit message (Collapse)AuthorFilesLines
2020-06-04[Ada] Ada_2020: contracts for formal subprogramsEd Schonberg2-3/+224
2020-06-04 Ed Schonberg <schonberg@adacore.com> gcc/ada/ * sem_ch12.adb (Build_Suprogram_Body_Wrapper, Build_Subprogram_Decl_Wrapper): New suprograms, to create the wrappers needed to implement contracts on formsl subprograms at the point of instantiation. (Build_Subprogram_Wrappers): New subprogram within Analyze_Associations, calls the above when the formal subprogram has contracts, and expansion is enabled. (Instantiate_Formal_Subprogram): If the actual is not an entity, such as a function attribute, or a synchronized operation, create a function with an internal name and call it within the wrapper. (Analyze_Generic_Formal_Part): Analyze contracts at the end of the list of formal declarations. * sem_prag.adb (Analyze_Pre_Post_Condtion): In Ada_2020 the aspect and corresponding pragma can appear on a formal subprogram declaration. (Find_Related_Declaration_Or_Body): Ditto.
2020-06-04[Ada] Add missing conversion in call to Finalize primitiveEric Botcazou1-0/+9
2020-06-04 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * exp_ch7.adb (Make_Final_Call): Set the type of the object, if it is unanalyzed, before calling Convert_View on it.
2020-06-04[Ada] Get rid of Disable_FE_Inline_AlwaysArnaud Charlet4-8/+4
2020-06-04 Arnaud Charlet <charlet@adacore.com> gcc/ada/ * adabkend.adb, back_end.ads, opt.ads, sem_ch6.adb: Get rid of Disable_FE_Inline_Always.
2020-06-04[Ada] Fix a couple of oversights in previous changeEric Botcazou2-4/+17
2020-06-04 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * exp_ch7.adb (Make_Final_Call): Add missing guard. * sem_ch3.adb (Copy_And_Build): Adjust recursive call for private types. (Build_Derived_Private_Type): Deal with underlying full views.
2020-06-04[Ada] Put_Image attributeBob Duff43-224/+3612
2020-06-04 Bob Duff <duff@adacore.com> gcc/ada/ * libgnat/a-stobbu.adb, libgnat/a-stobbu.ads, libgnat/a-stobfi.adb, libgnat/a-stobfi.ads, libgnat/a-stoubu.adb, libgnat/a-stoubu.ads, libgnat/a-stoufi.adb, libgnat/a-stoufi.ads, libgnat/a-stoufo.adb, libgnat/a-stoufo.ads, libgnat/a-stouut.adb, libgnat/a-stouut.ads, libgnat/a-stteou.ads, libgnat/s-putaim.adb, libgnat/s-putaim.ads, libgnat/s-putima.adb, libgnat/s-putima.ads (Ada.Strings.Text_Output and children, System.Put_Images): New runtime support for Put_Image. * gcc-interface/Make-lang.in (GNAT_ADA_OBJS): Add exp_put_image.o. * exp_put_image.adb, exp_put_image.ads: New compiler package that generates calls to runtime routines that implement Put_Image. * Makefile.rtl: Add object files for Ada.Strings.Text_Output and children and System.Put_Images. * aspects.adb: Simplify initialization of Canonical_Aspect. * aspects.ads: Improve documentation. Add Aspect_Put_Image. * exp_attr.adb: Add support for Put_Image, by calling routines in Exp_Put_Image. * sem_util.adb (Is_Predefined_Dispatching_Operation): Return True for new TSS_Put_Image operation. * exp_ch3.adb: For tagged types, build a dispatching TSS_Put_Image operation by calling routines in Exp_Put_Image. * exp_disp.adb, exp_disp.ads: Make TSS_Put_Image be number 10, adjusting other operations' numbers after 10. We choose 10 because that's the last number shared by all runtimes. * exp_strm.adb: Use named notation as appropriate. * exp_cg.adb, exp_tss.ads: Add TSS_Put_Image. * libgnat/a-tags.ads: Modify Max_Predef_Prims for the new TSS_Put_Image. * impunit.adb: Add new runtime packages. * rtsfind.adb, rtsfind.ads: Add support for Ada.Strings.Text_Output, Ada.Strings.Text_Output.Utils, and System.Put_Images. * sem_attr.adb: Error checking for Put_Image calls. * sem_ch12.adb (Valid_Default_Attribute): Support for passing Put_Image as a generic formal parameter. * sem_ch13.adb: Analysis of Put_Image aspect. Turn it into a Put_Image attribute definition clause. * sem_ch8.adb (Analyze_Subprogram_Renaming): Support for renaming of the Put_Image attribute. * snames.adb-tmpl: Fix comments. * snames.ads-tmpl (Name_Put_Image): New Name_Id. (Attribute_Put_Image): New Attribute_Id. * tbuild.adb, tbuild.ads (Make_Increment): New utility.
2020-06-04[Ada] Alignment clause ignored on completion derived from private typeEric Botcazou7-81/+70
2020-06-04 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * exp_attr.adb (xpand_N_Attribute_Reference) <Input>: Call Find_Inherited_TSS to look up the Stream_Read TSS. <Output>: Likewise for the Stream_Write TSS. * exp_ch7.adb (Make_Final_Call): Call Underlying_Type on private types to account for underlying full views. * exp_strm.ads (Build_Record_Or_Elementary_Input_Function): Remove Use_Underlying parameter. * exp_strm.adb (Build_Record_Or_Elementary_Input_Function): Likewise and adjust accordingly. * exp_tss.adb (Find_Inherited_TSS): Deal with full views. Call Find_Inherited_TSS recursively on the parent type if the base type is a derived type. * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Take into account underlying full views for derived types. * sem_ch3.adb (Copy_And_Build): Look up the underlying full view only for a completion. Be prepared for private types. (Build_Derived_Private_Type): Build an underlying full view for a completion in the general case too.
2020-06-04[Ada] Remove OpenACC supportArnaud Charlet13-2666/+837
2020-06-04 Arnaud Charlet <charlet@adacore.com> gcc/ada/ * back_end.adb, opt.ads, par-prag.adb, sem_ch5.adb, sem_prag.adb, sinfo.adb, sinfo.ads, snames.ads-tmpl, doc/gnat_rm/implementation_defined_pragmas.rst: Remove experimental support for OpenACC. * gcc-interface/misc.c, gcc-interface/trans.c, gcc-interface/lang.opt: Ditto. * gnat_rm.texi: Regenerate. gcc/testsuite/ * gnat.dg/openacc1.adb: Remove testcase.
2020-06-04[Ada] Remove obsolete reference to gigi in commentEric Botcazou1-3/+0
2020-06-04 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * checks.adb (Generate_Discriminant_Check): Remove obsolete comment.
2020-06-04[Ada] Implement AI12-0275 (Make subtype_mark optional in object renamings)Gary Dismukes4-7/+145
2020-06-04 Gary Dismukes <dismukes@adacore.com> gcc/ada/ * par-ch3.adb (P_Identifier_Declarations): Add parsing of object renamings that have neither a subtype_mark nor an access_definition. Issue an error if the version is earlier than Ada_2020, and suggest using -gnatX. * sem_ch8.adb (Analyze_Object_Renaming): Handle object_renaming_declarations that don't have an explicit subtype. Errors are issued when the name is inappropriate or ambiguous, and otherwise the Etype of the renaming entity is set from the Etype of the renamed object. * sem_util.adb (Has_Null_Exclusion): Allow for the case of no subtype given in an N_Object_Renaming_Declaration. * sprint.adb (Sprint_Node_Actual): Handle printing of N_Object_Renaming_Declarations that are specified without an explicit subtype.
2020-06-04[Ada] Fix glitch for N_Delta_Aggregate/N_Case_Expression/N_Quantified_ExpressionEric Botcazou1-2/+4
2020-06-04 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * sinfo.ads (N_Delta_Aggregate): Document Etype field. (N_Case_Expression): Likewise. (Is_Syntactic_Field) <N_Quantified_Expression>: Adjust. <N_Case_Expression>: Likewise.
2020-06-04[Ada] Avoid redefining IS_DIR_SEPARATOR macroArnaud Charlet1-6/+6
2020-06-04 Arnaud Charlet <charlet@adacore.com> gcc/ada/ * adaint.c: Avoid redefining IS_DIR_SEPARATOR macro.
2020-06-04[Ada] Wrong walk order in Walk_Library_ItemsArnaud Charlet1-13/+30
2020-06-04 Arnaud Charlet <charlet@adacore.com> gcc/ada/ * sem.adb (Walk_Library_Items): Defer processing of main spec after all other specs and before processing bodies.
2020-06-04[Ada] Import Adafinal as convention AdaArnaud Charlet1-1/+1
2020-06-04 Arnaud Charlet <charlet@adacore.com> gcc/ada/ * bindgen.adb (Gen_Adafinal): Adafinal is convention Ada, not C.
2020-06-04[Ada] Incorrect source line range on subprogram body with contractEd Schonberg1-0/+10
2020-06-04 Ed Schonberg <schonberg@adacore.com> gcc/ada/ * sinput.adb (Sloc_Range): Ignore node in the tree if it appears in a unit different from that of the node whose Sloc range we are computing. This is necessary when computing the source range of a subprogram body whose declaration includes a pre- or postcondition, because declaration and body may appear in different units, and the expanded code for the body includes copies of the contract code.
2020-06-04[Ada] Revamp dump and aux output namesAlexandre Oliva1-1/+4
2020-06-04 Alexandre Oliva <oliva@adacore.com> gcc/ada/ * switch.adb (Is_Internal_GCC_Switch): Recognize dumpdir and dumpbase-ext. Mark auxbase and auxbase-strip for removal.
2020-06-04[Ada] Set convention and inlined flag on default null procedureEric Botcazou2-1/+8
2020-06-04 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * sem_attr.adb (Resolve_Attribute) <Access>: Do not generate the secondary message about a missing pragma if the convention of the prefix is Intrinsic. * sem_ch12.adb (Instantiate_Formal_Subprogram): Only set the Convention and the Is_Inlined flag on a null procedure.
2020-06-04[Ada] Missing accessibility check on access discriminant in extended returnJustin Squirek1-22/+39
2020-06-04 Justin Squirek <squirek@adacore.com> gcc/ada/ * sem_ch6.adb (Check_Return_Obj_Accessibility): Change to Check_Return_Construct_Accessibility to better reflect its purpose. Add loop to properly obtain the object declaration from an expanded extended return statement and add calls to get the original node for associated values. Also, avoid checks when the return statement being examined comes from an internally generated function.
2020-06-04[Ada] Fix Is_Absolute_Path on WindowsDmitriy Anisimkov1-4/+8
2020-06-04 Dmitriy Anisimkov <anisimko@adacore.com> gcc/ada/ * adaint.c (__gnat_is_absolute_path): Check for directory separator after drive and colon. (IS_DIR_SEPARATOR): Define new inline substitution.
2020-06-04[Ada] Update the documentation in checks.ads about range checksEric Botcazou1-25/+17
2020-06-04 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * checks.ads: Update documentation about range checks and fix minor other things.
2020-06-04[Ada] Small tweak to special handling of private index typesEric Botcazou1-3/+6
2020-06-04 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * sem_ch3.adb (Array_Type_Declaration): Apply special handling of private index types to generic packages and restrict it to index types defined in the current scope.
2020-06-04[Ada] New procedure Register_Global_Unhandled_ActionArnaud Charlet5-10/+52
2020-06-04 Arnaud Charlet <charlet@adacore.com> gcc/ada/ * libgnat/a-exextr.adb (Global_Unhandled_Action): New global variable. (Notify_Exception): Take into account Global_Unhandled_Action and fix latent race condition. (Exception_Action): Mark Favor_Top_Level so that variables can be atomic. (Global_Action): Mark atomic to remove the need for a lock. * libgnat/g-excact.ads, libgnat/g-excact.adb (Register_Global_Unhandled_Action): New procedure. (Register_Global_Action): Remove lock. * libgnat/s-stalib.ads (Raise_Action): Mark Favor_Top_Level to be compatible with Exception_Action. * sem_warn.adb (Warn_On_Unreferenced_Entity): Fix logic wrt Volatile entities and entities with an address clause: the code did not match the comment/intent.
2020-06-04[Ada] Update URL and bug report instructionsArnaud Charlet1-4/+4
2020-06-04 Arnaud Charlet <charlet@adacore.com> gcc/ada/ * comperr.adb (Compiler_Abort): Update URL and bug report instructions.
2020-06-04[Ada] Avoid buffer overflow in Long_Long_Float_Text_IOSteve Baird3-10/+10
2020-06-04 Steve Baird <baird@adacore.com> gcc/ada/ * libgnat/s-imgrea.ads: Declare a named number Max_Real_Image_Length with value 5200. Provide a comment explaining why this value was chosen. * libgnat/s-imgrea.adb (Set_Image_Real): Increase the upper bound of the local String variable Digs to Max_Real_Image_Length. * libgnat/a-tiflau.adb (Put): Increase the upper bound of the local String variable Buf to Max_Real_Image_Length. (Puts): Increase the upper bound of the local String variable Buf to Max_Real_Image_Length.
2020-06-04[Ada] Remove System.Parameters.Single_LockArnaud Charlet33-1375/+283
2020-06-04 Arnaud Charlet <charlet@adacore.com> gcc/ada/ * libgnarl/a-dynpri.adb, libgnarl/a-taside.adb, libgnarl/a-taster.adb, libgnarl/s-interr.adb, libgnarl/s-interr__sigaction.adb, libgnarl/s-taasde.adb, libgnarl/s-taenca.adb, libgnarl/s-taenca.ads, libgnarl/s-taprop.ads, libgnarl/s-taprop__hpux-dce.adb, libgnarl/s-taprop__linux.adb, libgnarl/s-taprop__mingw.adb, libgnarl/s-taprop__posix.adb, libgnarl/s-taprop__qnx.adb, libgnarl/s-taprop__solaris.adb, libgnarl/s-taprop__vxworks.adb, libgnarl/s-tarest.adb, libgnarl/s-tasini.adb, libgnarl/s-tasque.adb, libgnarl/s-tasque.ads, libgnarl/s-tasren.adb, libgnarl/s-tasren.ads, libgnarl/s-tassta.adb, libgnarl/s-tasuti.adb, libgnarl/s-tasuti.ads, libgnarl/s-tpoben.adb, libgnarl/s-tpobop.adb, libgnarl/s-tpopmo.adb, libgnarl/s-tposen.adb, libgnat/s-parame.ads, libgnat/s-parame__ae653.ads, libgnat/s-parame__hpux.ads, libgnat/s-parame__vxworks.ads: Remove references to Single_Lock and Global_Lock.
2020-06-04[Ada] Continuation of "Get rid of more references to Universal_Integer"Arnaud Charlet2-6/+6
2020-06-04 Arnaud Charlet <charlet@adacore.com> gcc/ada/ * libgnat/s-atopar.adb, libgnat/s-atopex.adb: Use Object_Size instead of Size, otherwise many derived types will be rejected (e.g. a type with a 14 bits 'Size and a 16 bits 'Object_Size).
2020-06-04[Ada] Add another ad-hoc case to the Has_Private_View mechanismEric Botcazou1-0/+31
2020-06-04 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * sem_ch12.adb (Copy_Generic_Node): Add special handling for a conversion between access types.
2020-06-04[Ada] Fix fallout of cleanup to Has_Private_View mechanismEric Botcazou1-0/+31
2020-06-04 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * sem_ch12.adb (Check_Generic_Actuals): Also restore the proper views of the actuals of the parent instances if the formals are used as actuals of the children. (Instantiate_Type): Add comment.
2020-06-04[Ada] Minor editorial fixesGary Dismukes1-2/+2
2020-06-04 Gary Dismukes <dismukes@adacore.com> gcc/ada/ * sem_ch12.adb: Minor editorial fixes.
2020-06-04Daily bump.GCC Administrator1-0/+250
2020-06-03[Ada] Fix for missing calls to Adjust primitive with nested genericsEric Botcazou1-126/+81
2020-06-03 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * sem_ch12.adb (Denotes_Previous_Actual): Delete. (Check_Generic_Actuals): Do not special case array types whose component type denotes a previous actual. Do not special case access types whose base type is private. (Check_Private_View): Remove code dealing with secondary types. Do not switch the views of an array because of its component. (Copy_Generic_Node): Add special handling for a comparison operator on array types. (Instantiate_Type): Do not special case access types whose designated type is private. (Set_Global_Type): Do not special case array types whose component type is private.
2020-06-03[Ada] Spurious ineffective with clause warnings on use type clauseJustin Squirek1-7/+18
2020-06-03 Justin Squirek <squirek@adacore.com> gcc/ada/ * sem_ch10.adb (Process_Body_Clauses): Add loop to interate through all prefixes in a use_type clause so that all packages in the expanded name get examined for effectiveness.
2020-06-03[Ada] Small housekeeping work in Check_Private_ViewEric Botcazou1-19/+9
2020-06-03 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * sem_ch12.adb (Check_Private_View): Clean up implementation of second main case, when the generic sees the private declaration.
2020-06-03[Ada] Add detection of uninitialized big realsArnaud Charlet3-8/+39
2020-06-03 Arnaud Charlet <charlet@adacore.com> gcc/ada/ * libgnat/a-nbnbin.ads: Minor reformatting. * libgnat/a-nbnbre.ads, libgnat/a-nbnbre.adb (Is_Valid): Add convention Intrinsic. Add detection of uninitialized big reals.
2020-06-03[Ada] Remove more cases of empty loopsArnaud Charlet3-16/+113
2020-06-03 Arnaud Charlet <charlet@adacore.com> gcc/ada/ * sem_util.ads, sem_util.adb (Side_Effect_Free_Statements, Side_Effect_Free_Loop): New functions. (Has_Non_Null_Statements): Consider N_Call_Marker as a null statement. * sem_ch5.adb (Analyze_Loop_Parameter_Specification): Call Set_Is_Null_Loop even inside a generic instantiation. (Analyze_Loop_Statement): Mark for removal loops with no side effects.
2020-06-03[Ada] Support pragma Allow_Integer_Address on 64-bit targetsEric Botcazou4-11/+33
2020-06-03 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * opt.ads (Allow_Integer_Address): Fix typo in comment. * stand.ads (Standard_Address): New entity. * cstand.adb (Create_Standard): Create it. * sem_ch4.adb (Operator_Check): Convert the operands of an operation with addresses and integers to Standard_Address if pragma Allow_Integer_Address is in effect.
2020-06-03[Ada] Get rid of more references to Universal_Integer in expanded codeEric Botcazou2-6/+8
2020-06-03 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * libgnat/s-atopar.adb (Atomic_Fetch_And_Add): Make use of an equivalent static expression. (Atomic_Fetch_And_Subtract): Likewise. (Is_Lock_Free): Likewise. * libgnat/s-atopex.adb (Atomic_Exchange): Likewise. (Atomic_Compare_And_Exchange): Likewise. (Is_Lock_Free): Likewise.
2020-06-03[Ada] Fix typosVadim Godunko3-3/+3
2020-06-03 Vadim Godunko <godunko@adacore.com> gcc/ada/ * libgnat/s-parame.ads, libgnat/s-parame__ae653.ads, libgnat/s-parame__hpux.ads: Fix typos.
2020-06-03[Ada] Avoid creating temporaries in Universal_Integer, continuedEric Botcazou1-6/+9
2020-06-03 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * exp_util.adb (Remove_Side_Effects): For a type conversion, do not remove the side effects of the expression only if it is of universal integer type.
2020-06-03[Ada] Update headersArnaud Charlet4-0/+16
2020-06-03 Arnaud Charlet <charlet@adacore.com> gcc/ada/ * libgnat/s-aotase.ads, libgnat/s-atoope.ads, libgnat/s-atopar.ads, libgnat/s-atopex.ads: Update header.
2020-06-03[Ada] Small improvement to Expand_N_Unchecked_Type_ConversionEric Botcazou1-3/+3
2020-06-03 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * exp_ch4.adb (Expand_N_Unchecked_Type_Conversion): Also fold the conversion for literals of enumeration types.
2020-06-03[Ada] Improve handling of SPARK_Mode in generic instancesYannick Moy4-10/+39
2020-06-03 Yannick Moy <moy@adacore.com> gcc/ada/ * rtsfind.adb (Load_RTU): Correctly set/reset global variable to ignore SPARK_Mode in instances around loading. * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Accept Off without prior On. * sem_ch7.adb (Analyze_Package_Body_Helper): Likewise. * sem_prag.adb (Analyze_Pragma): Always take into account SPARK_Mode Off.
2020-06-03[Ada] Initial infrastructure for adding a tree checkerArnaud Charlet5-2/+101
2020-06-03 Arnaud Charlet <charlet@adacore.com> gcc/ada/ * frontend.adb (Frontend): Call (dummy for now) tree checker. * debug.adb: Reserve -gnatd_V for the tree checker. * vast.ads, vast.adb: New files. * gcc-interface/Make-lang.in: Add vast.o.
2020-06-03[Ada] Incorrect accessibility checking on aliased formalsJustin Squirek9-67/+134
2020-06-03 Justin Squirek <squirek@adacore.com> gcc/ada/ * libgnat/a-cborse.adb, libgnat/a-cihase.adb, libgnat/a-ciorse.adb, libgnat/a-coorse.adb: Modified to use 'Unrestricted_Access in certain cases where static accessibility errors were triggered. * exp_ch6.adb (Expand_Simple_Return_Statement): Add generation of dynamic accessibility checks as determined by Is_Special_Aliased_Formal_Access. * sem_attr.adb (Resolve_Attribute): Add call to Is_Special_Aliased_Formal_Access to avoid performing static checks where dynamic ones are required. * sem_ch6.adb (Check_Return_Obj_Accessibility): Handle renamed objects within component associations requiring special accessibility checks. * sem_util.adb, sem_util.ads (Is_Special_Aliased_Formal_Access): Created to detect the special case where an aliased formal is being compared against the level of an anonymous access return object. (Object_Access_Level): Remove incorrect condition leading to overly permissive accessibility levels being returned on explicitly aliased parameters.
2020-06-03[Ada] Improve 'Val implementation for some enumeration typesEric Botcazou3-158/+208
2020-06-03 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * einfo.ads (Enum_Pos_To_Rep): Adjust description. * exp_attr.adb (Expand_N_Attribute_Reference) <Pred>: Reimplement in the case of an enumeration type with non-standard but contiguous representation. <Succ>: Likewise. <Val>: Likewise. * exp_ch3.adb (Expand_Freeze_Enumeration_Type): Count the literals in the first loop. If the representation is contiguous, just build the index type of the array type and set Enum_Pos_To_Rep to it.
2020-06-03[Ada] Unnesting problems with expansion of Loop_Entry attributeGary Dismukes1-11/+25
2020-06-03 Gary Dismukes <dismukes@adacore.com> gcc/ada/ * exp_attr.adb (Expand_Loop_Entry_Attribute): Revise loop that resets the scopes of entities associated with Loop_Id to the scope of the new function, so the resetting is not restricted to itypes, but excludes loop parameters and the function entity itself. However, this fix is believed to be incomplete and a ??? comment is added to indicate that.
2020-06-03[Ada] Minor change to comment in System.Regexp specBob Duff1-2/+4
2020-06-03 Bob Duff <duff@adacore.com> gcc/ada/ * libgnat/s-regexp.ads: Fix comment
2020-06-03[Ada] Get rid of more references to Universal_Integer in expanded codeEric Botcazou1-80/+128
2020-06-03 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * exp_attr.adb (Expand_N_Attribute_Reference) <Enum_Rep>: In the case of an enumeration type, do an intermediate conversion to a small integer type. Remove useless stuff. <Finalization_Size>: Do not hardcode Universal_Integer and fix a type mismatch in the assignment to the variable. <Max_Size_In_Storage_Elements>: Likewise. <From_Any>: Do not redefine the Ptyp local variable. <To_Any>: Likewise. <TypeCode>: Likewise. <Pos>: Small tweaks. <Val>: For an enumeration type with standard representation, apply the range check to the expression of a convertion to Universal_Integer, if any. For an integer type, expand to a mere conversion.
2020-06-03[Ada] More efficient System.Random_Numbers.Random_Discrete for 32-bit typesEric Botcazou1-22/+67
2020-06-03 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * libgnat/s-rannum.adb (Random_Discrete): In the 32-bit case, use the same linear implementation as in the 64-bit case when the type has a contiguous representation.
2020-06-03[Ada] Debug info not available on subp having a class-wide preconditionGary Dismukes1-0/+7
2020-06-03 Gary Dismukes <dismukes@adacore.com> gcc/ada/ * sem_util.adb (Build_Class_Wide_Clone_Decl): Call Set_Debug_Info_Needed to set the Needs_Debug_Info flag on Clone_Id if the flag is set on Spec_Id.
2020-06-03[Ada] Fix missing overflow checks in analysis of predefined unitYannick Moy1-1/+9
2020-06-03 Yannick Moy <moy@adacore.com> gcc/ada/ * inline.adb (Expand_Inlined_Call): Do not suppress checks on inlined code in GNATprove mode.