aboutsummaryrefslogtreecommitdiff
path: root/gcc/java/jcf-write.c
diff options
context:
space:
mode:
authorRoger Sayle <roger@eyesopen.com>2006-02-04 18:57:53 +0000
committerRoger Sayle <sayle@gcc.gnu.org>2006-02-04 18:57:53 +0000
commit5460aa9c92db4858927d7a7c2118e71d7c90aa6d (patch)
treec0d1e0f40e8cd4dc49d6721aa72f8082ff6c8750 /gcc/java/jcf-write.c
parentdd4ebf6ae9d708b231ad929bbe6fa900fb336a02 (diff)
downloadgcc-5460aa9c92db4858927d7a7c2118e71d7c90aa6d.zip
gcc-5460aa9c92db4858927d7a7c2118e71d7c90aa6d.tar.gz
gcc-5460aa9c92db4858927d7a7c2118e71d7c90aa6d.tar.bz2
decl.c (java_init_decl_processing): Create char_type_node as a regular INTEGER_TYPE node.
* decl.c (java_init_decl_processing): Create char_type_node as a regular INTEGER_TYPE node. (push_promoted_type): Preserve TYPE_STRING_FLAG on types. * typeck.c (convert): No longer check for CHAR_TYPEs but instead test for char_type_node and promoted_char_type_node as special instances of INTEGER_TYPE tree codes. (promote_type,build_java_signature): Likewise. * jcf-write.c (adjust_typed_op): Likewise. * mangle.c (mangle_type): Likewise. * parse.y (do_unary_numeric_promotion): No longer handle CHAR_TYPE. * parse.h (JINTEGRAL_TYPE_P): Likewise. From-SVN: r110592
Diffstat (limited to 'gcc/java/jcf-write.c')
-rw-r--r--gcc/java/jcf-write.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/java/jcf-write.c b/gcc/java/jcf-write.c
index c090173..5343361 100644
--- a/gcc/java/jcf-write.c
+++ b/gcc/java/jcf-write.c
@@ -875,9 +875,9 @@ adjust_typed_op (tree type, int max)
case RECORD_TYPE: return 4;
case BOOLEAN_TYPE:
return TYPE_PRECISION (type) == 32 || max < 5 ? 0 : 5;
- case CHAR_TYPE:
- return TYPE_PRECISION (type) == 32 || max < 6 ? 0 : 6;
case INTEGER_TYPE:
+ if (type == char_type_node || type == promoted_char_type_node)
+ return TYPE_PRECISION (type) == 32 || max < 6 ? 0 : 6;
switch (TYPE_PRECISION (type))
{
case 8: return max < 5 ? 0 : 5;