Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
riscv-gcc-1
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
riscv-gcc-1
Commits
edde779b
Commit
edde779b
authored
May 26, 2008
by
Arnaud Charlet
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* sem_attr.adb: Add some ??? comments for previous change
From-SVN: r135949
parent
45c87b72
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
1 deletions
+19
-1
gcc/ada/sem_attr.adb
+19
-1
No files found.
gcc/ada/sem_attr.adb
View file @
edde779b
...
...
@@ -8089,8 +8089,26 @@ package body Sem_Attr is
--
Arr
(
X
..
Y
)
'address is identical to Arr (X)'
address
,
--
even
if
the
array
is
packed
and
the
slice
itself
is
not
--
addressable
.
Transform
the
prefix
into
an
indexed
component
.
--
Note
that
the
transformation
is
safe
only
if
we
know
that
--
the
slice
is
non
-
null
.
--
the
slice
is
non
-
null
.
That
is
because
a
null
slice
can
have
--
an
out
of
bounds
index
value
.
--
Right
now
,
gigi
blows
up
if
given
'Address on a slice, and
-- this covers up that bug in one case, but the bug is likely
-- still there in the cases not transformed by this code ???
-- It'
s
not
clear
what
'Address *should* return for a null
-- slice with out of bounds indexes, this might be worth an ARG
-- discussion ???
-- One approach would be to do a length check unconditionally,
-- and then do the transformation below unconditionally, but
-- analyze with checks off, avoiding the problem of the out of
-- bounds index. This approach would interpret the address of
-- an out of bounds null slice as being the address where the
-- array element would be if there was one, which is probably
-- as reasonable an interpretation as any ???
declare
Loc : constant Source_Ptr := Sloc (P);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment