From ea517ca550bf8a1bed19dda72e731d717465850c Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Wed, 10 Jan 2007 22:56:20 +0000 Subject: [PATCH] natDouble.cc (toString): Added parens. * java/lang/natDouble.cc (toString): Added parens. * gnu/gcj/io/shs.h (PROTO): Define. * link.cc (resolve_pool_entry): Added missing braces. From-SVN: r120652 --- libjava/ChangeLog | 6 ++++++ libjava/gnu/gcj/io/shs.h | 2 ++ libjava/java/lang/natDouble.cc | 4 ++-- libjava/link.cc | 24 +++++++++++++----------- 4 files changed, 23 insertions(+), 13 deletions(-) diff --git a/libjava/ChangeLog b/libjava/ChangeLog index 2b9931e79e1..e3393ed9df7 100644 --- a/libjava/ChangeLog +++ b/libjava/ChangeLog @@ -1,3 +1,9 @@ +2007-01-10 Tom Tromey + + * java/lang/natDouble.cc (toString): Added parens. + * gnu/gcj/io/shs.h (PROTO): Define. + * link.cc (resolve_pool_entry): Added missing braces. + 2007-01-10 H.J. Lu PR libgcj/30424 diff --git a/libjava/gnu/gcj/io/shs.h b/libjava/gnu/gcj/io/shs.h index 1b435c5df8e..c4b2d5a30b0 100644 --- a/libjava/gnu/gcj/io/shs.h +++ b/libjava/gnu/gcj/io/shs.h @@ -31,6 +31,8 @@ typedef unsigned int uint32_t __attribute__((mode(SI))); # endif #endif +#define PROTO + /* The SHS block size and message digest sizes, in bytes */ #define SHS_BLOCKSIZE 64 diff --git a/libjava/java/lang/natDouble.cc b/libjava/java/lang/natDouble.cc index 1a33a57158e..87123bc1bc6 100644 --- a/libjava/java/lang/natDouble.cc +++ b/libjava/java/lang/natDouble.cc @@ -1,6 +1,6 @@ // natDouble.cc - Implementation of java.lang.VMDouble native methods. -/* Copyright (C) 1998, 1999, 2000, 2001, 2003, 2005, 2006 Free Software Foundation +/* Copyright (C) 1998, 1999, 2000, 2001, 2003, 2005, 2006, 2007 Free Software Foundation This file is part of libgcj. @@ -87,7 +87,7 @@ java::lang::VMDouble::toString(jdouble value, jboolean isFloat) if (sign) *d++ = '-'; - if (value >= 1e-3 && value < 1e7 || value == 0) + if ((value >= 1e-3 && value < 1e7) || value == 0) { if (decpt <= 0) *d++ = '0'; diff --git a/libjava/link.cc b/libjava/link.cc index 929be3a8702..7f398889a29 100644 --- a/libjava/link.cc +++ b/libjava/link.cc @@ -1,6 +1,6 @@ // link.cc - Code for linking and resolving classes and pool entries. -/* Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation +/* Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation This file is part of libgcj. @@ -408,16 +408,18 @@ _Jv_Linker::resolve_pool_entry (jclass klass, int index, bool lazy) // with it should just throw a NoClassDefFoundError with the class' // name. if (! found) - if (lazy) - { - found = _Jv_NewClass(name, NULL, NULL); - found->state = JV_STATE_PHANTOM; - pool->tags[index] |= JV_CONSTANT_ResolvedFlag; - pool->data[index].clazz = found; - break; - } - else - throw new java::lang::NoClassDefFoundError (name->toString()); + { + if (lazy) + { + found = _Jv_NewClass(name, NULL, NULL); + found->state = JV_STATE_PHANTOM; + pool->tags[index] |= JV_CONSTANT_ResolvedFlag; + pool->data[index].clazz = found; + break; + } + else + throw new java::lang::NoClassDefFoundError (name->toString()); + } // Check accessibility, but first strip array types as // _Jv_ClassNameSamePackage can't handle arrays.