2003-12-26 Guilhem Lavaux <guilhem@kaffe.org>
[official-gcc.git] / libjava / testsuite / libjava.lang / Float_1.java
blobcb147ee8aca9ddd0ba710eef1a8e8f1e83c3075a
1 /*
3 Date: 25 Aug 1998 16:04:00 -0000
4 From: Andrew Haley <aph@pasanda.cygnus.co.uk>
5 To: java-project@cygnus.com
6 Subject: Help: vtable problem?
8 My little program:
10 -----------------------------------------------------------------------
11 import java.lang.*;
13 public class widget
15 public static void main (String argv[])
17 int test = Float.floatToIntBits((float)2.0);
18 String s = Integer.toHexString(test);
20 System.out.print (s+"\n");
24 -----------------------------------------------------------------------
25 prints out
27 40000000
29 with Sun's interpreter, but prints out
31 true
33 when compiled with gcj; PrintStream dispatches a string arg as a
34 boolean rather than as a String. I've tried to rebuild everything.
38 Thanks,
39 Andrew.
43 public class Float_1
45 public static void main (String argv[])
47 int test = Float.floatToIntBits((float)2.0);
48 String s = Integer.toHexString(test);
50 System.out.print (s+"\n");