OSDN Git Service
(root)
/
pf3gnuchains
/
gcc-fork.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0fe4905
)
(c_sizeof): Call force_fit_type only for INTEGER_CST.
author
rms
<rms@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 5 Jan 1993 22:52:25 +0000
(22:52 +0000)
committer
rms
<rms@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 5 Jan 1993 22:52:25 +0000
(22:52 +0000)
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@3103
138bc75d
-0d04-0410-961f-
82ee72b054a4
gcc/c-typeck.c
patch
|
blob
|
history
diff --git
a/gcc/c-typeck.c
b/gcc/c-typeck.c
index
756b610
..
04134a0
100644
(file)
--- a/
gcc/c-typeck.c
+++ b/
gcc/c-typeck.c
@@
-727,7
+727,9
@@
c_sizeof (type)
/* Convert in case a char is more than one unit. */
t = size_binop (CEIL_DIV_EXPR, TYPE_SIZE (type),
size_int (TYPE_PRECISION (char_type_node)));
- force_fit_type (t);
+ /* size_binop does not put the constant in range, so do it now. */
+ if (TREE_CODE (t) == INTEGER_CST)
+ force_fit_type (t);
return t;
}