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
cdfa2b24
Commit
cdfa2b24
authored
8 years ago
by
Ville Voutilainen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Revert the attempted fix for c++/69855, it breaks bootstrap.
From-SVN: r236844
parent
f3c82ff9
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
5 additions
and
68 deletions
+5
-68
gcc/cp/name-lookup.c
+0
-18
gcc/testsuite/g++.dg/overload/69855.C
+0
-44
gcc/testsuite/g++.old-deja/g++.law/missed-error2.C
+3
-4
gcc/testsuite/g++.old-deja/g++.pt/crash3.C
+2
-2
No files found.
gcc/cp/name-lookup.c
View file @
cdfa2b24
...
...
@@ -929,24 +929,6 @@ pushdecl_maybe_friend_1 (tree x, bool is_friend)
DECL_ANTICIPATED
(
t
)
=
1
;
DECL_HIDDEN_FRIEND_P
(
t
)
=
1
;
}
if
(
TREE_CODE
(
x
)
==
FUNCTION_DECL
&&
DECL_LOCAL_FUNCTION_P
(
x
)
&&
!
DECL_OMP_DECLARE_REDUCTION_P
(
x
)
&&
!
type_dependent_expression_p
(
x
))
{
/* PR c++/69855, a local function declaration
is stripped from template info and pushed to
the local scope as a hidden declaration. This
allows ill-formed overloads even in other scopes
to be diagnosed both at the local declaration site
and after it. */
tree
t2
=
copy_decl
(
t
);
DECL_USE_TEMPLATE
(
t2
)
=
0
;
DECL_TEMPLATE_INFO
(
t2
)
=
NULL_TREE
;
DECL_ANTICIPATED
(
t2
)
=
1
;
push_overloaded_decl
(
t2
,
PUSH_GLOBAL
,
is_friend
);
}
}
if
(
t
!=
x
||
DECL_FUNCTION_TEMPLATE_P
(
t
))
...
...
This diff is collapsed.
Click to expand it.
gcc/testsuite/g++.dg/overload/69855.C
deleted
100644 → 0
View file @
f3c82ff9
// PR c++/69855
// { dg-do compile }
int
get
();
void
f
()
{
char
get
();
// { dg-error "ambiguating" }
}
int
get2
();
char
get2
(
int
);
void
f2
()
{
char
get2
();
// { dg-error "ambiguating" }
}
char
get3
(
int
);
void
f3
()
{
char
get3
();
}
void
f4
()
{
char
get4
();
}
int
get4
();
// { dg-error "ambiguating" }
void
get5
();
template
<
class
T
>
struct
X
{
void
g
()
{
int
get5
();
// { dg-error "ambiguating" }
}
};
template
<
class
T
>
struct
X2
{
void
g
()
{
int
get6
();
}
};
void
get6
();
// { dg-error "ambiguating" }
This diff is collapsed.
Click to expand it.
gcc/testsuite/g++.old-deja/g++.law/missed-error2.C
View file @
cdfa2b24
...
...
@@ -25,10 +25,9 @@ int main() {
foo
(
4
,
-
37
,
14
.
39
,
14
.
38
);
}
// 971006 we no longer gave an error for this since we emit a hard error
// about the declaration above, but after the fix for PR c++/69855
// this declaration emits a diagnostic again
static
void
foo
(
int
i
,
int
j
,
double
x
,
double
y
)
{
// { dg-error "extern|static" }
// 971006 we no longer give an error for this since we emit a hard error
// about the declaration above
static
void
foo
(
int
i
,
int
j
,
double
x
,
double
y
)
{
std
::
cout
<<
"Max(int): "
<<
max
(
i
,
j
)
<<
" Max(double): "
<<
max
(
x
,
y
)
<<
'\n'
;
...
...
This diff is collapsed.
Click to expand it.
gcc/testsuite/g++.old-deja/g++.pt/crash3.C
View file @
cdfa2b24
...
...
@@ -10,7 +10,7 @@ public:
}
CVector
<
long
>
g
()
const
{
CVector
<
long
>
v
2
();
return
v
2
;
CVector
<
long
>
v
();
return
v
;
}
};
This diff is collapsed.
Click to expand it.
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