This is the mail archive of the
kawa@sourceware.cygnus.com
mailing list for the Kawa project.
Re: Kawa bug report
"Vince D. Calhoun" <vcalhoun@jhu.edu> writes:
> (string? (number->string 2.5))
> You will get #f instead of #t.
>
> Could you take a look at this? Let me know if you need more information.
Please try this patch:
Index: number2string.java
===================================================================
RCS file: /cvs/kawa/kawa/kawa/standard/number2string.java,v
retrieving revision 1.6
diff -u -r1.6 number2string.java
--- number2string.java 2000/03/18 18:50:42 1.6
+++ number2string.java 2000/04/11 22:25:37
@@ -5,23 +5,23 @@
public class number2string extends Procedure1or2
{
- public static String apply (Object arg, int radix)
+ public static FString apply (Object arg, int radix)
{
- return ((Numeric)arg).toString (radix);
+ return new FString(((Numeric)arg).toString (radix));
}
- public static String apply (Object arg)
+ public static FString apply (Object arg)
{
- return ((Numeric)arg).toString(10);
+ return new FString(((Numeric)arg).toString(10));
}
public final Object apply1 (Object arg1)
{
- return new FString(apply(arg1));
+ return apply(arg1);
}
public final Object apply2 (Object arg1, Object arg2)
{
- return new FString(apply(arg1, ((IntNum) arg2).intValue()));
+ return apply(arg1, ((IntNum) arg2).intValue());
}
}
--
--Per Bothner
per@bothner.com http://www.bothner.com/~per/