diff options
| author | nathan <nathan@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-08-20 09:13:12 +0000 |
|---|---|---|
| committer | nathan <nathan@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-08-20 09:13:12 +0000 |
| commit | 59d526f9c5354be1a9ac840aafb76473a7f31b64 (patch) | |
| tree | 4008f9e7bab98c919ce8e8f44d4cdcfc93150a6c /gcc/java/expr.c | |
| parent | aac0b61ce812a644ea424b3c2c270768237dbf32 (diff) | |
| download | ppe42-gcc-59d526f9c5354be1a9ac840aafb76473a7f31b64.tar.gz ppe42-gcc-59d526f9c5354be1a9ac840aafb76473a7f31b64.zip | |
* expr.c (build_java_arrayaccess): Use convert to change
len's type.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@86307 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/java/expr.c')
| -rw-r--r-- | gcc/java/expr.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/java/expr.c b/gcc/java/expr.c index 9472794dfee..97f540aac16 100644 --- a/gcc/java/expr.c +++ b/gcc/java/expr.c @@ -763,8 +763,8 @@ build_java_arrayaccess (tree array, tree type, tree index) * Note this is equivalent to and more efficient than: * INDEX < 0 || INDEX >= LEN && throw ... */ tree test; - tree len = build_java_array_length_access (array); - TREE_TYPE (len) = unsigned_int_type_node; + tree len = convert (unsigned_int_type_node, + build_java_array_length_access (array)); test = fold (build2 (GE_EXPR, boolean_type_node, convert (unsigned_int_type_node, index), len)); |

