aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@gcc.gnu.org>2014-07-29 16:46:27 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2014-07-29 16:46:27 +0200
commit09176aea40fcc440cbedae0b222de8724888fa4e (patch)
tree8ba554d642cd65c3d924d6770093c6c80c66f6b1
parent1b4ada8ff0a07ce407259c81248d813a295f9c41 (diff)
downloadgcc-09176aea40fcc440cbedae0b222de8724888fa4e.zip
gcc-09176aea40fcc440cbedae0b222de8724888fa4e.tar.gz
gcc-09176aea40fcc440cbedae0b222de8724888fa4e.tar.bz2
[multiple changes]
2014-07-29 Robert Dewar <dewar@adacore.com> * gnat_rm.texi, sem_prag.adb: Minor reformatting. 2014-07-29 Sergey Rybin <rybin@adacore.com frybin> * gnat_ugn.texi: gnatmetric: clarify documentation for cyclomatic complexity metrics. 2014-07-29 Thomas Quinot <quinot@adacore.com> PR ada/60652 * s-oscons-tmplt.c: For Linux, define _BSD_SOURCE in order for CRTSCTS to be visible. 2014-07-29 Bob Duff <duff@adacore.com> * g-trasym.adb, g-trasym.ads: Code cleanup. From-SVN: r213201
-rw-r--r--gcc/ada/ChangeLog19
-rw-r--r--gcc/ada/g-trasym.adb6
-rw-r--r--gcc/ada/g-trasym.ads7
-rw-r--r--gcc/ada/gnat_rm.texi33
-rw-r--r--gcc/ada/gnat_ugn.texi18
-rw-r--r--gcc/ada/s-oscons-tmplt.c15
-rw-r--r--gcc/ada/sem_prag.adb5
7 files changed, 83 insertions, 20 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog
index ac5a3ac..eb1e9f7 100644
--- a/gcc/ada/ChangeLog
+++ b/gcc/ada/ChangeLog
@@ -1,3 +1,22 @@
+2014-07-29 Robert Dewar <dewar@adacore.com>
+
+ * gnat_rm.texi, sem_prag.adb: Minor reformatting.
+
+2014-07-29 Sergey Rybin <rybin@adacore.com frybin>
+
+ * gnat_ugn.texi: gnatmetric: clarify documentation for cyclomatic
+ complexity metrics.
+
+2014-07-29 Thomas Quinot <quinot@adacore.com>
+
+ PR ada/60652
+ * s-oscons-tmplt.c: For Linux, define _BSD_SOURCE in order for
+ CRTSCTS to be visible.
+
+2014-07-29 Bob Duff <duff@adacore.com>
+
+ * g-trasym.adb, g-trasym.ads: Code cleanup.
+
2014-07-29 Doug Rupp <rupp@adacore.com>
* sigtramp-vxworks.c: Minor reformatting.
diff --git a/gcc/ada/g-trasym.adb b/gcc/ada/g-trasym.adb
index a825f80..35d4020 100644
--- a/gcc/ada/g-trasym.adb
+++ b/gcc/ada/g-trasym.adb
@@ -6,7 +6,7 @@
-- --
-- B o d y --
-- --
--- Copyright (C) 1999-2012, AdaCore --
+-- Copyright (C) 1999-2014, AdaCore --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
@@ -69,7 +69,9 @@ package body GNAT.Traceback.Symbolic is
end if;
end Symbolic_Traceback;
- function Symbolic_Traceback (E : Exception_Occurrence) return String is
+ function Symbolic_Traceback
+ (E : Ada.Exceptions.Exception_Occurrence) return String
+ is
begin
return Symbolic_Traceback (Tracebacks (E));
end Symbolic_Traceback;
diff --git a/gcc/ada/g-trasym.ads b/gcc/ada/g-trasym.ads
index 62bb632..a3ac108 100644
--- a/gcc/ada/g-trasym.ads
+++ b/gcc/ada/g-trasym.ads
@@ -6,7 +6,7 @@
-- --
-- S p e c --
-- --
--- Copyright (C) 1999-2012, AdaCore --
+-- Copyright (C) 1999-2014, AdaCore --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
@@ -84,7 +84,7 @@
-- Symbolic_Traceback return a list of addresses expressed as "0x..."
-- separated by line feed.
-with Ada.Exceptions; use Ada.Exceptions;
+with Ada.Exceptions;
package GNAT.Traceback.Symbolic is
pragma Elaborate_Body;
@@ -94,7 +94,8 @@ package GNAT.Traceback.Symbolic is
-- Note: This procedure may be installed by Set_Trace_Decorator, to get a
-- symbolic traceback on all exceptions raised (see GNAT.Exception_Traces).
- function Symbolic_Traceback (E : Exception_Occurrence) return String;
+ function Symbolic_Traceback
+ (E : Ada.Exceptions.Exception_Occurrence) return String;
-- Build string containing symbolic traceback of given exception occurrence
end GNAT.Traceback.Symbolic;
diff --git a/gcc/ada/gnat_rm.texi b/gcc/ada/gnat_rm.texi
index d631fd7..6f6e0ed 100644
--- a/gcc/ada/gnat_rm.texi
+++ b/gcc/ada/gnat_rm.texi
@@ -4573,7 +4573,9 @@ There are five supported optimization hints for a loop:
@itemize @bullet
@item Ivdep
-The programmer asserts that there are no loop-carried dependencies which would prevent consecutive iterations of the loop from being executed simultaneously.
+The programmer asserts that there are no loop-carried dependencies
+which would prevent consecutive iterations of the loop from being
+executed simultaneously.
@item No_Unroll
@@ -4599,7 +4601,7 @@ unrolling, but there is no guarantee that the loop will be vectorized.
@end itemize
-These hints do not void the need to pass the appropriate switches to the
+These hints do not remove the need to pass the appropriate switches to the
compiler in order to enable the relevant optimizations, that is to say
@option{-funroll-loops} for unrolling and @option{-ftree-vectorize} for
vectorization.
@@ -8345,7 +8347,30 @@ that it is separately controllable using pragma @code{Assertion_Policy}.
@unnumberedsec Aspect Iterable
@findex Iterable
@noindent
-PLEASE ADD DOCUMENTATION HERE???
+This aspect is used in the GNAT-defined formal container packages, to provide
+a light-weight mechanism for loops over such containers, without the overhead
+imposed by the tampering checks of standard Ada2012 iterators. The value of the
+aspect is a aggregate with four named components: First, Next, Has_Element,
+and Element. The following is a typical example of use:
+
+@smallexample @c ada
+type List is private with
+ Iterable => (First => First_Element,
+ Next => Advance,
+ Has_Element => Get_Element,
+ Element => List_Element);
+@end smallexample
+@itemize @bullet
+@item The value denoted by @code{First} must denote a primitive operation of
+the container type that returns a Cursor, which must a be a type declared in
+the container package.
+@item The value of @code{Next} is a primitive operation of the container type
+that takes a cursor and yields a cursor.
+@item @code{Has_Element} is an operation that applies to a cursor a yields an
+element of the container.
+@item @code{Element} is the type of the elements of the container type, and
+thus the result of the function denoted by Has_Element.
+@end itemize
@node Aspect Linker_Section
@unnumberedsec Aspect Linker_Section
@@ -9107,7 +9132,7 @@ relevant environment variables at run time.
@unnumberedsec Attribute Iterable
@findex Iterable
@noindent
-PLEASE ADD DOCUMENTATION HERE???
+Equivalent to Aspect Iterable.
@node Attribute Large
@unnumberedsec Attribute Large
diff --git a/gcc/ada/gnat_ugn.texi b/gcc/ada/gnat_ugn.texi
index 3c43f25..2dcdb4f 100644
--- a/gcc/ada/gnat_ugn.texi
+++ b/gcc/ada/gnat_ugn.texi
@@ -16222,14 +16222,17 @@ and quantified expressions. For each body, we compute three metric values:
@itemize @bullet
@item
the complexity introduced by control
-statements only, without taking into account short-circuit forms,
+statements only, without taking into account short-circuit forms
+(referred as @code{statement complexity} in @command{gnatmetric} output),
@item
-the complexity introduced by short-circuit control forms only, and
+the complexity introduced by short-circuit control forms only
+(referred as @code{expression complexity} in @command{gnatmetric} output), and
@item
the total
-cyclomatic complexity, which is the sum of these two values.
+cyclomatic complexity, which is the sum of these two values
+(referred as @code{cyclomatic complexity} in @command{gnatmetric} output).
@end itemize
@noindent
@@ -19851,8 +19854,8 @@ Specifies whether or not passed tests should be shown. @var{val} can be either
@item --tests-root=@var{dirname}
@cindex @option{--tests-root} (@command{gnattest})
-The directory hierarchy of tested sources is recreated in the @var{dirname}
-directory, and test packages are placed in corresponding directories.
+The hierarchy of source directories, if any, is recreated in the @var{dirname}
+directory, with test packages placed in directories corresponding to those of the sources.
If the @var{dirname} is a relative path, it is considered relative to the object
directory of the project file. When all sources from all projects are taken
recursively from all projects, directory hierarchies of tested sources are
@@ -19861,7 +19864,10 @@ placed accordingly.
@item --subdir=@var{dirname}
@cindex @option{--subdir} (@command{gnattest})
-Test packages are placed in subdirectories.
+Test packages are placed in a subdirectory of the corresponding source directory,
+with the name @var{dirname}. Thus, each set of unit tests is located in a subdirectory of the
+code under test. If the sources are in separate directories, each source directory
+has a test subdirectory named @var{dirname}.
@item --tests-dir=@var{dirname}
@cindex @option{--tests-dir} (@command{gnattest})
diff --git a/gcc/ada/s-oscons-tmplt.c b/gcc/ada/s-oscons-tmplt.c
index 7fef245..de2b9b9 100644
--- a/gcc/ada/s-oscons-tmplt.c
+++ b/gcc/ada/s-oscons-tmplt.c
@@ -86,10 +86,17 @@ pragma Style_Checks ("M32766");
** a number of non-POSIX but useful/required features.
**/
-#if defined (__linux__) && !defined (_XOPEN_SOURCE)
-/* For Linux, define _XOPEN_SOURCE to get IOV_MAX */
-#define _XOPEN_SOURCE 500
-#endif
+#if defined (__linux__)
+
+/* Define _XOPEN_SOURCE to get IOV_MAX */
+# if !defined (_XOPEN_SOURCE)
+# define _XOPEN_SOURCE 500
+# endif
+
+/* Define _BSD_SOURCE to get CRTSCTS */
+# define _BSD_SOURCE
+
+#endif /* defined (__linux__) */
/* Include gsocket.h before any system header so it can redefine FD_SETSIZE */
diff --git a/gcc/ada/sem_prag.adb b/gcc/ada/sem_prag.adb
index dee225b..dac9342 100644
--- a/gcc/ada/sem_prag.adb
+++ b/gcc/ada/sem_prag.adb
@@ -16720,7 +16720,10 @@ package body Sem_Prag is
Hint := First (Pragma_Argument_Associations (N));
while Present (Hint) loop
Check_Arg_Is_One_Of (Hint, Name_Ivdep,
- Name_No_Unroll, Name_Unroll, Name_No_Vector, Name_Vector);
+ Name_No_Unroll,
+ Name_Unroll,
+ Name_No_Vector,
+ Name_Vector);
Next (Hint);
end loop;