* s-wchwts.adb:
(Wide_String_To_String): Returns a String with the same 'First as its
parameter S.
(Wide_Wide_String_To_String): Ditto
* s-wchwts.ads:
(Wide_String_To_String): Document that the lowest index of the returned
String is equal to S'First.
From-SVN: r138708
2008-08-05 Robert Dewar <dewar@adacore.com>
* opt.ads (Warn_On_Biased_Representation): New flag
* sem_ch13.adb:
(Analyze_Attribute_Definition_Clause): Issue warning when biased
representation is required.
(Minimum_Size): Don't allow biasing if enum rep clause case
* sem_warn.adb:
(Set_Dot_Warning_Switch): Add handling of -gnatw.b/B switches
(Set_Warning_Switch): Include -gnatw.b in -gnatwa, -gnatw.B in gnatws
* usage.adb: Add lines for -gnatw.b/B switches
From-SVN: r138704
2008-08-05 Ed Schonberg <schonberg@adacore.com>
* sem_ch12.adb (Validate_Array_Type_Instance): Only apply complex
visibility check on the component type if the simple test fails.
From-SVN: r138697
2008-08-05 Bob Duff <duff@adacore.com>
* sem_ch3.adb (Analyze_Object_Declaration): Avoid type Any_Access in
unresolved initial value of "null", because it causes implicitly
generated "=" operators to be ambiguous, and because this type should
not be passed to gigi.
From-SVN: r138693
2008-08-05 Jose Ruiz <ruiz@adacore.com>
* init.c (__gnat_install_handler for linux): If we are building the
Xenomai run time then we need to do two additional things: avoid
memory swapping and transform the Linux environment task into a native
Xenomai task.
* gcc-interface/Makefile.in (LIBGNAT_TARGET_PAIRS for xenomai run
time): Use interface to Xenomai native skin and avoid linux-specific
way of setting CPU affinity.
(EH_MECHANISM for the xenomai run time): Use sjlj exception mechanism.
From-SVN: r138684
2008-08-05 Vincent Celier <celier@adacore.com>
* make.adb (Switches_Of): Check for Switches (others), before checking
for Default_Switches ("Ada").
(Gnatmake): Use Builder'Switches (others) in preference to
Builder'Default_Switches ("Ada") if there are several mains.
* prj-attr-pm.adb:
(Add_Attribute): Add component Others_Allowed in Attribute_Record
aggregate.
* prj-attr.adb:
Add markers to indicates that attributes Switches allow others as index
(Others_Allowed_For): New Boolean function, returning True for
attributes with the mark.
(Initialize): Recognize optional letter 'O' as the marker for
associative array attributes where others is allowed as the index.
* prj-attr.ads:
(Others_Allowed_For): New Boolean function
(Attribute_Record): New Boolean component Others_Allowed
* prj-dect.adb:
(Parse_Attribute_Declaration): For associative array attribute where
others is allowed as the index, allow others as an index.
* prj-nmsc.adb:
(Process_Binder): Skip associative array attributes with index others
(Process_Compiler): Ditto
* prj-util.adb:
(Value_Of (Index, In_Array)): Make no attempt to put in lower case when
index is All_Other_Names.
* prj.ads:
(All_Other_Names): New constant
From-SVN: r138683
2008-08-05 Thomas Quinot <quinot@adacore.com>
* gen-soccon.c: Rename to gen-oscons.c
* gen-oscons.c: New file. Now generate System.OS_Constants instead of
GNAT.Sockets.Constants.
Add new constants for GNAT.Serial_Communications and System.File_IO.
From-SVN: r138679
2008-08-05 Javier Miranda <miranda@adacore.com>
* sem_util.adb (Collect_Interfaces_Info): Minor reformating.
* exp_ch3.adb (Build_Offset_To_Top_Functions): Code cleanup: the
implementation of this routine has been simplified.
From-SVN: r138675
2008-08-05 Ed Schonberg <schonberg@adacore.com>
* sem_res.adb (Resolve_Call): If this is a call to the predefined
Abort_Task, warn if the call appears within a protected operation.
From-SVN: r138672
2008-08-05 Ed Schonberg <schonberg@adacore.com>
* exp_strm.adb (Build_Record_Or_Elementary_Input_Function): For access
discriminants, indicate that the corresponding object declaration has
no initialization, to prevent spurious warnings when the access type is
null-excluding.
From-SVN: r138671
2008-08-05 Jerome Lambourg <lambourg@adacore.com>
* g-comlin.adb (Sort_Sections, Group_Switches): New/Modified internal
methods needed to handle switch sections when building a command line.
(Define_Section, Add_Switch, Remove_Switch, Is_New_Section,
Current_Section): New public methods or methods modified to handle
building command lines with sections.
(Set_Command_Line): Take into account sections when analysing a switch
string.
(Start): Sort the switches by sections before iterating the command line
elements.
* g-comlin.ads (Define_Section, Add_Switch, Remove_Switch,
Is_New_Section, Current_Section): New methods or methods modified to
handle building command lines with sections.
From-SVN: r138670
* sem_ch3.adb:
(Replace_Anonymous_Access_To_Protected_Subprogram): Handle properly an
anonymous access to protected subprogram that is the return type of the
specification of a subprogram body.
* sem_ch6.adb:
(Analyze_Subprogram_Body): if the return type is an anonymous access to
subprogram, freeze it now to prevent access anomalies in the back-end.
* exp_ch9.adb: Minor code cleanup.
Make sure that new declarations are inserted into the tree before
analysis (from code reading).
From-SVN: r138650
2008-08-04 Richard Guenther <rguenther@suse.de>
* tree-ssa-loop-ivopts.c (add_iv_value_candidates): Also add
the candidate with the stripped base if that base is different
from the original base even for offset zero.
From-SVN: r138647