diff options
| author | John David Anglin <dave@hiauly1.hia.nrc.ca> | 2002-10-11 21:10:00 +0000 |
|---|---|---|
| committer | John David Anglin <danglin@gcc.gnu.org> | 2002-10-11 21:10:00 +0000 |
| commit | a0bed689af362730fc12c06706035d679d7c4a69 (patch) | |
| tree | 70e569fabd7c20b1d482290090569a1e037d0fb9 /gcc/tree.c | |
| parent | db6556348d92709dfaa930251b5aa0fd5cb740c3 (diff) | |
| download | gcc-a0bed689af362730fc12c06706035d679d7c4a69.zip gcc-a0bed689af362730fc12c06706035d679d7c4a69.tar.gz gcc-a0bed689af362730fc12c06706035d679d7c4a69.tar.bz2 | |
cfganal.c (dfs_enumerate_from): Use PARAMS.
* cfganal.c (dfs_enumerate_from): Use PARAMS.
* genautomata.c (output_insn_code_cases): Likewise.
* real.c (real_format): Likewise.
* tree.c (tree_size): Revise expressions using TREE_CODE_LENGTH to
ensure value is promoted before doing subtraction.
From-SVN: r58064
Diffstat (limited to 'gcc/tree.c')
| -rw-r--r-- | gcc/tree.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -177,7 +177,7 @@ tree_size (node) case '1': /* a unary arithmetic expression */ case '2': /* a binary arithmetic expression */ return (sizeof (struct tree_exp) - + (TREE_CODE_LENGTH (code) - 1) * sizeof (char *)); + + TREE_CODE_LENGTH (code) * sizeof (char *) - sizeof (char *)); case 'c': /* a constant */ /* We can't use TREE_CODE_LENGTH for INTEGER_CST, since the number of @@ -199,7 +199,7 @@ tree_size (node) length = (sizeof (struct tree_common) + TREE_CODE_LENGTH (code) * sizeof (char *)); if (code == TREE_VEC) - length += (TREE_VEC_LENGTH (node) - 1) * sizeof (char *); + length += TREE_VEC_LENGTH (node) * sizeof (char *) - sizeof (char *); return length; } |
