summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2012-10-29 11:39:21 +0000
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2012-10-29 11:39:21 +0000
commitfcee6529bbcd36bfec66aa85cf26f01a84c3b088 (patch)
tree937710befbf5802b0c05dced6a8bcac9706eab32
parentc2db7c545567e4519a02a15883539fd122e3644a (diff)
downloadppe42-gcc-fcee6529bbcd36bfec66aa85cf26f01a84c3b088.tar.gz
ppe42-gcc-fcee6529bbcd36bfec66aa85cf26f01a84c3b088.zip
2012-10-29 Gary Dismukes <dismukes@adacore.com>
* exp_alfa.adb: Minor reformatting. 2012-10-29 Robert Dewar <dewar@adacore.com> * gnat_rm.texi, gnat_ugn.texi: Clarify documentation on maximum line length style switch. 2012-10-29 Robert Dewar <dewar@adacore.com> * layout.adb (Set_Composite_Alignment): Ignore pragma Optimize_Alignment (Space) for packed variable length records. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@192938 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ada/ChangeLog14
-rw-r--r--gcc/ada/exp_alfa.adb4
-rw-r--r--gcc/ada/gnat_rm.texi8
-rw-r--r--gcc/ada/gnat_ugn.texi5
-rw-r--r--gcc/ada/layout.adb7
5 files changed, 32 insertions, 6 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog
index cf5fbb5e9f7..8542c7d8bf5 100644
--- a/gcc/ada/ChangeLog
+++ b/gcc/ada/ChangeLog
@@ -1,3 +1,17 @@
+2012-10-29 Gary Dismukes <dismukes@adacore.com>
+
+ * exp_alfa.adb: Minor reformatting.
+
+2012-10-29 Robert Dewar <dewar@adacore.com>
+
+ * gnat_rm.texi, gnat_ugn.texi: Clarify documentation on maximum
+ line length style switch.
+
+2012-10-29 Robert Dewar <dewar@adacore.com>
+
+ * layout.adb (Set_Composite_Alignment): Ignore pragma
+ Optimize_Alignment (Space) for packed variable length records.
+
2012-10-29 Robert Dewar <dewar@adacore.com>
* s-bignum.adb: Minor comment change.
diff --git a/gcc/ada/exp_alfa.adb b/gcc/ada/exp_alfa.adb
index 5c44849aaf8..1aac781e3aa 100644
--- a/gcc/ada/exp_alfa.adb
+++ b/gcc/ada/exp_alfa.adb
@@ -80,11 +80,11 @@ package body Exp_Alfa is
when N_Attribute_Reference =>
Expand_Alfa_N_Attribute_Reference (N);
- -- Note: we use to qualify entity names in the following constructs
+ -- Note: we used to qualify entity names in the following constructs
-- (as full expansion does), but this was removed as this prevents
-- the verification back-end from using a short name for debugging
-- and user interaction. The verification back-end already takes
- -- care of qualifying names when needed
+ -- care of qualifying names when needed.
when N_Block_Statement |
N_Package_Body |
diff --git a/gcc/ada/gnat_rm.texi b/gcc/ada/gnat_rm.texi
index c6e092c81ca..2afdb676687 100644
--- a/gcc/ada/gnat_rm.texi
+++ b/gcc/ada/gnat_rm.texi
@@ -9553,8 +9553,12 @@ See separate section on source representation.
length. See 2.2(15).
@end cartouche
@noindent
-The maximum line length is 255 characters and the maximum length of a
-lexical element is also 255 characters.
+The maximum line length is 255 characters and the maximum length of
+a lexical element is also 255 characters. This is the default setting
+if not overridden by the use of compiler switch @option{-gnaty} (which
+sets the maximum to 79) or @option{-gnatyMnn} which allows the maximum
+line length to be specified to be any value up to 32767. The maximum
+length of a lexical element is the same as the maximum line length.
@sp 1
@cartouche
diff --git a/gcc/ada/gnat_ugn.texi b/gcc/ada/gnat_ugn.texi
index 53df9a19984..2455b880a7b 100644
--- a/gcc/ada/gnat_ugn.texi
+++ b/gcc/ada/gnat_ugn.texi
@@ -6657,13 +6657,16 @@ any trailing blanks. The value of 79 allows convenient display on an
80 character wide device or window, allowing for possible special
treatment of 80 character lines. Note that this count is of
characters in the source text. This means that a tab character counts
-as one character in this count but a wide character sequence counts as
+as one character in this count and a wide character sequence counts as
a single character (however many bytes are needed in the encoding).
@item ^Mnnn^MAX_LENGTH=nnn^
@emph{Set maximum line length.}
The length of lines must not exceed the
given value @option{nnn}. The maximum value that can be specified is 32767.
+If neither style option for setting the line length is used, then the
+default is 255. This also controls the maximum length of lexical elements,
+where the only restriction is that they must fit on a single line.
@item ^n^STANDARD_CASING^
@emph{Check casing of entities in Standard.}
diff --git a/gcc/ada/layout.adb b/gcc/ada/layout.adb
index 1f44196bded..651107f24c4 100644
--- a/gcc/ada/layout.adb
+++ b/gcc/ada/layout.adb
@@ -2882,7 +2882,12 @@ package body Layout is
and then Is_Packed (E)
and then not Is_Atomic (E)
then
- Align := 1;
+ if not Size_Known_At_Compile_Time (E) then
+ Error_Msg_N ("Optimize_Alignment has no effect for &", E);
+ Error_Msg_N ("\pragma is ignored for variable length record?", E);
+ else
+ Align := 1;
+ end if;
-- Not a record, or not packed
OpenPOWER on IntegriCloud