From owner-freebsd-java Fri Feb 14 23: 7:41 2003 Delivered-To: freebsd-java@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A4C4937B401 for ; Fri, 14 Feb 2003 23:07:40 -0800 (PST) Received: from chen.org.nz (chen.org.nz [210.54.19.51]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9BF5F43F85 for ; Fri, 14 Feb 2003 23:07:39 -0800 (PST) (envelope-from jonc@chen.org.nz) Received: from grimoire.chen.org.nz (localhost [127.0.0.1]) by chen.org.nz (8.12.7/8.12.7) with ESMTP id h1F73KqR000804; Sat, 15 Feb 2003 20:03:20 +1300 (NZDT) (envelope-from jonc@grimoire.chen.org.nz) Received: (from jonc@localhost) by grimoire.chen.org.nz (8.12.7/8.12.7/Submit) id h1F73IXa000803; Sat, 15 Feb 2003 20:03:18 +1300 (NZDT) Date: Sat, 15 Feb 2003 20:03:18 +1300 From: Jonathan Chen To: Huang wen hui Cc: Greg Lewis , java@FreeBSD.ORG Subject: Re: Math.pow bug for jdk1.3.1-p8 ? Message-ID: <20030215070318.GA655@grimoire.chen.org.nz> References: <3E4C9DDD.4040204@gddsn.org.cn> <20030215092059.A8186@misty.eyesbeyond.com> <3E4D8F19.4050204@gddsn.org.cn> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3E4D8F19.4050204@gddsn.org.cn> User-Agent: Mutt/1.4i Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Sat, Feb 15, 2003 at 08:51:37AM +0800, Huang wen hui wrote: [...] > >>public class TestPow { > >>public static void main(String[] args) { > >>int exp =9; > >>int i = (int)Math.pow(2.0,(double)exp); > >>System.out.println("i="+i); > >>} > >>} > >> > >>----------output------------ > >>%java TestPow > >>i=0 I can confirm the problem on my machine as well: % uname -a FreeBSD grimoire.chen.org.nz 4.7-STABLE FreeBSD 4.7-STABLE #0: Sat Feb 15 15:42:09 NZDT 2003 root@grimoire.chen.org.nz:/usr/obj/usr/src/sys/GRIMOIRE i386 % java -version java version "1.3.1-p8" Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1-p8-root-030214-07:23) Classic VM (build 1.3.1-p8-root-030214-07:23, green threads, nojit) % java TestPow i = 0 Java was built using base-system's cc. -- Jonathan Chen ---------------------------------------------------------------------- Power corrupts, Absolute Power is pretty neat To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message