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
1ddde1cd
Commit
1ddde1cd
authored
Jun 23, 1992
by
Richard Stallman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
*** empty log message ***
From-SVN: r1239
parent
d24eed4d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
2 deletions
+17
-2
gcc/stmt.c
+17
-2
No files found.
gcc/stmt.c
View file @
1ddde1cd
...
...
@@ -3444,10 +3444,10 @@ check_for_full_enumeration_handling (type)
n
=
n
->
right
)
;
if
(
!
(
n
&&
tree_int_cst_equal
(
n
->
low
,
TREE_VALUE
(
chain
))
))
if
(
!
n
||
tree_int_cst_lt
(
TREE_VALUE
(
chain
),
n
->
low
))
{
if
(
warn_switch
)
warning
(
"enumerat
ed
value `%s' not handled in switch"
,
warning
(
"enumerat
ion
value `%s' not handled in switch"
,
IDENTIFIER_POINTER
(
TREE_PURPOSE
(
chain
)));
all_values
=
0
;
}
...
...
@@ -3473,6 +3473,21 @@ check_for_full_enumeration_handling (type)
==
IDENTIFIER_NODE
)
?
TYPE_NAME
(
type
)
:
DECL_NAME
(
TYPE_NAME
(
type
))));
if
(
!
tree_int_cst_equal
(
n
->
low
,
n
->
high
))
{
for
(
chain
=
TYPE_VALUES
(
type
);
chain
&&
!
tree_int_cst_equal
(
n
->
high
,
TREE_VALUE
(
chain
));
chain
=
TREE_CHAIN
(
chain
))
;
if
(
!
chain
)
warning
(
"case value `%d' not in enumerated type `%s'"
,
TREE_INT_CST_LOW
(
n
->
high
),
IDENTIFIER_POINTER
((
TREE_CODE
(
TYPE_NAME
(
type
))
==
IDENTIFIER_NODE
)
?
TYPE_NAME
(
type
)
:
DECL_NAME
(
TYPE_NAME
(
type
))));
}
}
/* If all values were found as case labels, make one of them the default
...
...
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