[m-rev.] for review: implement math library for java

Fergus Henderson fjh at cs.mu.OZ.AU
Wed Dec 10 14:32:16 AEDT 2003


On 10-Dec-2003, James Goddard <goddardjames at yahoo.com> wrote:
> Implement some library procedures for the Java
> back-end.
> 
> library/math.m:
>         Added the ML_FLOAT_LN2 constant for Java:
>         Implement the following predicates for Java:
>                 domain_checks/0
>                 math__pi/1
>                 math__e/1
>                 math__ceiling/2
>                 math__floor/2
>                 math__round/2
>                 math__sqrt_2/2
>                 math__pow_2/3
>                 math__exp/2     <-- also fixed a typo
>                 math__ln_2/2
>                 math__log2_2/2
>                 math__sin/2
>                 math__cos/2
>                 math__tan/2
>                 math__asin_2/2
>                 math__acos_2/2
>                 math__atan/2
>                 math__atan2/3
>         Implement the following predicates in Mercury:
>                 math__sinh/2
>                 math__cosh/2
>                 math__tanh/2

That looks great, thanks!

Please test this using tests/general/float_test.m, and if it works,
go ahead and commit it.

The write_message predicate in float_test.m uses string__format,
which I think is not yet implemented for the Java back-end.  So you'll
probably have to temporarily modify it to use just io__write_string and
io__write_float instead of string__format.

-- 
Fergus Henderson <fjh at cs.mu.oz.au>  |  "I have always known that the pursuit
The University of Melbourne         |  of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh>  |     -- the last words of T. S. Garp.
--------------------------------------------------------------------------
mercury-reviews mailing list
post:  mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the reviews mailing list