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
ddce3528
Commit
ddce3528
authored
Feb 24, 1999
by
Jason Merrill
Committed by
Jason Merrill
Feb 24, 1999
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* pt.c (tsubst): Allow an array of explicit size zero.
From-SVN: r25400
parent
69688f1e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
3 deletions
+13
-3
gcc/cp/ChangeLog
+4
-0
gcc/cp/pt.c
+9
-3
No files found.
gcc/cp/ChangeLog
View file @
ddce3528
1999-02-24 Jason Merrill <jason@yorick.cygnus.com>
* pt.c (tsubst): Allow an array of explicit size zero.
1999-02-23 Jason Merrill <jason@yorick.cygnus.com>
1999-02-23 Jason Merrill <jason@yorick.cygnus.com>
* errfn.c: Change varargs code to look like toplev.c.
* errfn.c: Change varargs code to look like toplev.c.
...
...
gcc/cp/pt.c
View file @
ddce3528
...
@@ -6017,9 +6017,9 @@ tsubst (t, args, complain, in_decl)
...
@@ -6017,9 +6017,9 @@ tsubst (t, args, complain, in_decl)
return
t
;
return
t
;
{
{
tree
max
=
TREE_OPERAND
(
TYPE_MAX_VALUE
(
t
),
0
);
tree
max
,
omax
=
TREE_OPERAND
(
TYPE_MAX_VALUE
(
t
),
0
);
max
=
tsubst_expr
(
max
,
args
,
complain
,
in_decl
);
max
=
tsubst_expr
(
o
max
,
args
,
complain
,
in_decl
);
if
(
max
==
error_mark_node
)
if
(
max
==
error_mark_node
)
return
error_mark_node
;
return
error_mark_node
;
...
@@ -6032,7 +6032,13 @@ tsubst (t, args, complain, in_decl)
...
@@ -6032,7 +6032,13 @@ tsubst (t, args, complain, in_decl)
return
itype
;
return
itype
;
}
}
if
(
integer_zerop
(
max
)
||
INT_CST_LT
(
max
,
integer_zero_node
))
if
(
integer_zerop
(
omax
))
{
/* Still allow an explicit array of size zero. */
if
(
pedantic
)
pedwarn
(
"creating array with size zero"
);
}
else
if
(
integer_zerop
(
max
)
||
INT_CST_LT
(
max
,
integer_zero_node
))
{
{
/* [temp.deduct]
/* [temp.deduct]
...
...
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