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
479781c5
Commit
479781c5
authored
Aug 28, 1998
by
Mark Mitchell
Committed by
Mark Mitchell
Aug 28, 1998
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* lex.c (do_identifier): Fix thinko in previous change.
From-SVN: r22064
parent
818c8883
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
7 deletions
+15
-7
gcc/cp/ChangeLog
+7
-2
gcc/cp/lex.c
+8
-5
No files found.
gcc/cp/ChangeLog
View file @
479781c5
1998-08-28 Mark Mitchell <mark@markmitchell.com>
* lex.c (do_identifier): Fix thinko in previous change.
1998-08-28 Jason Merrill <jason@yorick.cygnus.com>
1998-08-28 Jason Merrill <jason@yorick.cygnus.com>
* search.c (dfs_search, binfo_for_vtable, dfs_bfv_helper): New fns.
* search.c (dfs_search, binfo_for_vtable, dfs_bfv_helper): New fns.
...
@@ -20,12 +24,13 @@
...
@@ -20,12 +24,13 @@
* decl.c (finish_enum): Don't set the TREE_TYPE for the
* decl.c (finish_enum): Don't set the TREE_TYPE for the
enumeration constant values if we're processing_template_decls.
enumeration constant values if we're processing_template_decls.
Don't set the type for the CONST_DECLs either; that's done in
Don't set the type for the CONST_DECLs either; that's done in
build_enumerator.
(
build_enumerator.
(build_enumerator): Take the enumeration type as a
(build_enumerator): Take the enumeration type as a
paramter.
param
e
ter.
* lex.c (do_identifier): Don't resolve enumeration constants while
* lex.c (do_identifier): Don't resolve enumeration constants while
processing template declarations, even if they happen to be
processing template declarations, even if they happen to be
TEMPLATE_PARM_INDEXs.
TEMPLATE_PARM_INDEXs.
* parse.y (current_enum_type): New variable.
* parse.y (current_enum_type): New variable.
(primary): Don't allow statement-expression in local classes just
(primary): Don't allow statement-expression in local classes just
as we don't in global classes.
as we don't in global classes.
...
...
gcc/cp/lex.c
View file @
479781c5
...
@@ -2985,11 +2985,14 @@ do_identifier (token, parsing, args)
...
@@ -2985,11 +2985,14 @@ do_identifier (token, parsing, args)
/* protected is OK, since it's an enum of `this'. */
/* protected is OK, since it's an enum of `this'. */
}
}
if
(
!
processing_template_decl
if
(
!
processing_template_decl
/* Don't resolve enumeration constants while processing
/* Really, if we're processing a template, we just want to
template declarations, unless they're for global
resolve template parameters, and not enumeration
enumerations and therefore cannot involve template
constants. But, they're hard to tell apart. (Note that
parameters. */
a non-type template parameter may have enumeration type.)
||
(
!
DECL_CONTEXT
(
id
)
Fortunately, there's no harm in resolving *global*
enumeration constants, since they can't depend on
template parameters. */
||
(
TREE_CODE
(
CP_DECL_CONTEXT
(
id
))
==
NAMESPACE_DECL
&&
TREE_CODE
(
DECL_INITIAL
(
id
))
==
TEMPLATE_PARM_INDEX
))
&&
TREE_CODE
(
DECL_INITIAL
(
id
))
==
TEMPLATE_PARM_INDEX
))
id
=
DECL_INITIAL
(
id
);
id
=
DECL_INITIAL
(
id
);
}
}
...
...
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