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
27f1984e
Commit
27f1984e
authored
Jul 16, 2004
by
Jason Merrill
Committed by
Jason Merrill
Jul 16, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
undo reversion
From-SVN: r84822
parent
a23ee064
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
1 deletions
+20
-1
gcc/cp/ChangeLog
+5
-0
gcc/cp/cp-lang.c
+15
-1
No files found.
gcc/cp/ChangeLog
View file @
27f1984e
...
@@ -60,6 +60,11 @@
...
@@ -60,6 +60,11 @@
(add_conversions): Likewise.
(add_conversions): Likewise.
* semantics.c (finish_member_declaration): Adjust call to add_method.
* semantics.c (finish_member_declaration): Adjust call to add_method.
2004-07-15 Jason Merrill <jason@redhat.com>
* cp-lang.c (cxx_types_compatible_p): To the middle-end,
references and pointers are compatible.
2004-07-15 Nathan Sidwell <nathan@codesourcery.com>
2004-07-15 Nathan Sidwell <nathan@codesourcery.com>
* decl.c (xref_basetypes): Refactor.
* decl.c (xref_basetypes): Refactor.
...
...
gcc/cp/cp-lang.c
View file @
27f1984e
...
@@ -317,9 +317,23 @@ cp_var_mod_type_p (tree type, tree fn)
...
@@ -317,9 +317,23 @@ cp_var_mod_type_p (tree type, tree fn)
return
false
;
return
false
;
}
}
/* This compares two types for equivalence ("compatible" in C-based languages).
This routine should only return 1 if it is sure. It should not be used
in contexts where erroneously returning 0 causes problems. */
static
int
cxx_types_compatible_p
(
tree
x
,
tree
y
)
static
int
cxx_types_compatible_p
(
tree
x
,
tree
y
)
{
{
return
same_type_ignoring_top_level_qualifiers_p
(
x
,
y
);
if
(
same_type_ignoring_top_level_qualifiers_p
(
x
,
y
))
return
1
;
/* Once we get to the middle-end, references and pointers are
interchangeable. FIXME should we try to replace all references with
pointers? */
if
(
POINTER_TYPE_P
(
x
)
&&
POINTER_TYPE_P
(
y
)
&&
same_type_p
(
TREE_TYPE
(
x
),
TREE_TYPE
(
y
)))
return
1
;
return
0
;
}
}
/* Construct a C++-aware pretty-printer for CONTEXT. It is assumed
/* Construct a C++-aware pretty-printer for CONTEXT. It is assumed
...
...
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