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
83566abf
Commit
83566abf
authored
Mar 18, 1998
by
Jason Merrill
Committed by
Jason Merrill
Mar 17, 1998
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* pt.c (push_template_decl): Only check primary templates.
From-SVN: r18653
parent
670960ac
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
5 deletions
+10
-5
gcc/cp/ChangeLog
+2
-0
gcc/cp/pt.c
+8
-5
No files found.
gcc/cp/ChangeLog
View file @
83566abf
Wed Mar 18 00:24:10 1998 Jason Merrill <jason@yorick.cygnus.com>
* pt.c (push_template_decl): Only check primary templates.
* pt.c (check_explicit_specialization): Complain about default args
in explicit specialization.
...
...
gcc/cp/pt.c
View file @
83566abf
...
...
@@ -1381,11 +1381,6 @@ push_template_decl (decl)
int
is_friend
=
(
TREE_CODE
(
decl
)
==
FUNCTION_DECL
&&
DECL_FRIEND_P
(
decl
));
if
(
current_lang_name
==
lang_name_c
)
cp_error
(
"template with C linkage"
);
if
(
TREE_CODE
(
decl
)
==
TYPE_DECL
&&
ANON_AGGRNAME_P
(
DECL_NAME
(
decl
)))
cp_error
(
"template class without a name"
);
if
(
is_friend
)
/* For a friend, we want the context of the friend function, not
the type of which it is a friend. */
...
...
@@ -1416,6 +1411,14 @@ push_template_decl (decl)
else
primary
=
0
;
if
(
primary
)
{
if
(
current_lang_name
==
lang_name_c
)
cp_error
(
"template with C linkage"
);
if
(
TREE_CODE
(
decl
)
==
TYPE_DECL
&&
ANON_AGGRNAME_P
(
DECL_NAME
(
decl
)))
cp_error
(
"template class without a name"
);
}
/* Partial specialization. */
if
(
TREE_CODE
(
decl
)
==
TYPE_DECL
&&
DECL_ARTIFICIAL
(
decl
)
&&
CLASSTYPE_TEMPLATE_SPECIALIZATION
(
TREE_TYPE
(
decl
)))
...
...
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