projects
/
platform
/
upstream
/
gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cd4341e
)
[Ada] Skip types in error for test to compute array size
author
Yannick Moy
<moy@adacore.com>
Wed, 26 May 2021 12:54:02 +0000
(14:54 +0200)
committer
Pierre-Marie de Rodat
<derodat@adacore.com>
Thu, 8 Jul 2021 13:34:19 +0000
(13:34 +0000)
gcc/ada/
* layout.adb (Layout_Type): Do not call Number_Dimensions if the
type does not have First_Index set.
gcc/ada/layout.adb
patch
|
blob
|
history
diff --git
a/gcc/ada/layout.adb
b/gcc/ada/layout.adb
index
ee8e281
..
de73193
100644
(file)
--- a/
gcc/ada/layout.adb
+++ b/
gcc/ada/layout.adb
@@
-498,6
+498,7
@@
package body Layout is
-- in GNAT, i.e. when Packed_Array_Impl_Type is set.
if Is_Array_Type (E)
+ and then Present (First_Index (E)) -- Skip types in error
and then Number_Dimensions (E) = 1
and then not Present (Packed_Array_Impl_Type (E))
and then Has_Pragma_Pack (E)