aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@gcc.gnu.org>2009-04-20 10:41:44 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2009-04-20 10:41:44 +0200
commitff2e7c1ed0d02599e7052d0f75c9657f0dd0edc0 (patch)
treecd580f83fa8c2bbdc7f124a7ec689c989f153195
parent26a43556c88b96c608246b39023bc698be3b751d (diff)
downloadgcc-ff2e7c1ed0d02599e7052d0f75c9657f0dd0edc0.zip
gcc-ff2e7c1ed0d02599e7052d0f75c9657f0dd0edc0.tar.gz
gcc-ff2e7c1ed0d02599e7052d0f75c9657f0dd0edc0.tar.bz2
[multiple changes]
2009-04-20 Arnaud Charlet <charlet@adacore.com> * opt.ads (Inspector_Mode): Update documentation of this flag. 2009-04-20 Thomas Quinot <quinot@adacore.com> * g-socket.ads: Minor reformatting * socket.c, gsocket.h (__gnat_get_h_errno, VxWorks case): No need to consider S_resolvLib error codes since we only use the hostLib wrappers. 2009-04-20 Eric Botcazou <ebotcazou@adacore.com> * sem_ch3.adb (Build_Derived_Private_Type): Insert the declaration of the Underlying_Record_View after that of the derived type. From-SVN: r146371
-rw-r--r--gcc/ada/ChangeLog16
-rw-r--r--gcc/ada/g-socket.ads6
-rw-r--r--gcc/ada/gsocket.h3
-rw-r--r--gcc/ada/opt.ads7
-rw-r--r--gcc/ada/sem_ch3.adb14
-rw-r--r--gcc/ada/socket.c24
6 files changed, 30 insertions, 40 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog
index 447a783..99f5be0 100644
--- a/gcc/ada/ChangeLog
+++ b/gcc/ada/ChangeLog
@@ -1,5 +1,21 @@
2009-04-20 Arnaud Charlet <charlet@adacore.com>
+ * opt.ads (Inspector_Mode): Update documentation of this flag.
+
+2009-04-20 Thomas Quinot <quinot@adacore.com>
+
+ * g-socket.ads: Minor reformatting
+
+ * socket.c, gsocket.h (__gnat_get_h_errno, VxWorks case): No need to
+ consider S_resolvLib error codes since we only use the hostLib wrappers.
+
+2009-04-20 Eric Botcazou <ebotcazou@adacore.com>
+
+ * sem_ch3.adb (Build_Derived_Private_Type): Insert the declaration
+ of the Underlying_Record_View after that of the derived type.
+
+2009-04-20 Arnaud Charlet <charlet@adacore.com>
+
* switch-c.adb (Scan_Front_End_Switches): Disable front-end inlining
in inspector mode.
diff --git a/gcc/ada/g-socket.ads b/gcc/ada/g-socket.ads
index f8dd6bf..009f567 100644
--- a/gcc/ada/g-socket.ads
+++ b/gcc/ada/g-socket.ads
@@ -1082,9 +1082,9 @@ package GNAT.Sockets is
Status : out Selector_Status;
Timeout : Selector_Duration := Forever);
-- This refined version of Check_Selector allows to watch for exception
- -- events (that is notifications of out-of-band transmission and
- -- reception). As above, all of R_Socket_Set, W_Socket_Set and
- -- E_Socket_Set must be different objects.
+ -- events (i.e. notifications of out-of-band transmission and reception).
+ -- As above, all of R_Socket_Set, W_Socket_Set and E_Socket_Set must be
+ -- different objects.
procedure Abort_Selector (Selector : Selector_Type);
-- Send an abort signal to the selector
diff --git a/gcc/ada/gsocket.h b/gcc/ada/gsocket.h
index 4a746ad..7e88eea 100644
--- a/gcc/ada/gsocket.h
+++ b/gcc/ada/gsocket.h
@@ -65,9 +65,6 @@
#include <vxWorks.h>
#include <ioLib.h>
#include <hostLib.h>
-#if (_WRS_VXWORKS_MAJOR != 6) && ! defined (__RTP__)
-#include <resolvLib.h>
-#endif
#define SHUT_RD 0
#define SHUT_WR 1
#define SHUT_RDWR 2
diff --git a/gcc/ada/opt.ads b/gcc/ada/opt.ads
index 57ddd06..4964534 100644
--- a/gcc/ada/opt.ads
+++ b/gcc/ada/opt.ads
@@ -640,9 +640,10 @@ package Opt is
Inspector_Mode : Boolean renames Debug.Debug_Flag_Dot_II;
-- GNAT
-- True if compiling in inspector mode (-gnatd.I switch).
- -- Only relevant when VM_Target /= None. The compiler will attempt to
- -- generate code even in case of unsupported construct, so that the byte
- -- code can be used by static analysis tools.
+ -- Enable inspector mode, in particular SCIL generation.
+ -- When VM_Target /= None, the compiler will also attempt to
+ -- generate code even in case of unsupported construct instead of
+ -- displaying an error.
Invalid_Value_Used : Boolean := False;
-- GNAT
diff --git a/gcc/ada/sem_ch3.adb b/gcc/ada/sem_ch3.adb
index b4e57b2..d53cb88 100644
--- a/gcc/ada/sem_ch3.adb
+++ b/gcc/ada/sem_ch3.adb
@@ -5552,7 +5552,10 @@ package body Sem_Ch3 is
(N, Parent_Type, Derived_Type, Derive_Subps);
-- Build anonymous completion, as a derivation from the full
- -- view of the parent.
+ -- view of the parent. Because it is used as a placeholder
+ -- to convey information to the back-end, it must be declared
+ -- after the original type so the back-end knows that it needs
+ -- to disregard the declaration.
Decl :=
Make_Full_Type_Declaration (Loc,
@@ -5574,11 +5577,9 @@ package body Sem_Ch3 is
-- Freeze the underlying record view, to prevent generation
-- of useless dispatching information, which is simply shared
- -- with the real derived type. The underlying view must be
- -- treated as an itype by the back-end.
+ -- with the real derived type.
Set_Is_Frozen (Full_Der);
- Set_Is_Itype (Full_Der);
Set_Underlying_Record_View (Derived_Type, Full_Der);
end;
@@ -13495,7 +13496,7 @@ package body Sem_Ch3 is
elsif No (Interface_List (N)) then
Error_Msg_N
("completion of tagged private type must be tagged",
- N);
+ N);
end if;
elsif Nkind (N) = N_Full_Type_Declaration
@@ -13504,8 +13505,7 @@ package body Sem_Ch3 is
and then Interface_Present (Type_Definition (N))
then
Error_Msg_N
- ("completion of private type canot be an interface",
- N);
+ ("completion of private type cannot be an interface", N);
end if;
-- Ada 2005 (AI-251): Private extension declaration of a task
diff --git a/gcc/ada/socket.c b/gcc/ada/socket.c
index a49f087..33a0639 100644
--- a/gcc/ada/socket.c
+++ b/gcc/ada/socket.c
@@ -351,36 +351,17 @@ __gnat_get_h_errno (void) {
case 0:
return 0;
-#ifdef S_resolvLib_HOST_NOT_FOUND
- case S_resolvLib_HOST_NOT_FOUND:
-#endif
#ifdef S_hostLib_HOST_NOT_FOUND
case S_hostLib_HOST_NOT_FOUND:
#endif
case S_hostLib_UNKNOWN_HOST:
return HOST_NOT_FOUND;
-#ifdef S_resolvLib_TRY_AGAIN
- case S_resolvLib_TRY_AGAIN:
- return TRY_AGAIN;
-#endif
#ifdef S_hostLib_TRY_AGAIN
case S_hostLib_TRY_AGAIN:
return TRY_AGAIN;
#endif
-#ifdef S_resolvLib_NO_RECOVERY
- case S_resolvLib_NO_RECOVERY:
-#endif
-#ifdef S_resolvLib_BUFFER_2_SMALL
- case S_resolvLib_BUFFER_2_SMALL:
-#endif
-#ifdef S_resolvLib_INVALID_PARAMETER
- case S_resolvLib_INVALID_PARAMETER:
-#endif
-#ifdef S_resolvLib_INVALID_ADDRESS
- case S_resolvLib_INVALID_ADDRESS:
-#endif
#ifdef S_hostLib_NO_RECOVERY
case S_hostLib_NO_RECOVERY:
#endif
@@ -390,11 +371,6 @@ __gnat_get_h_errno (void) {
case S_hostLib_INVALID_PARAMETER:
return NO_RECOVERY;
-#ifdef S_resolvLib_NO_DATA
- case S_resolvLib_NO_DATA:
- return NO_DATA;
-#endif
-
default:
return -1;
}