[Shootout-list] Directions of various benchmarks

Jon Harrop jon@ffconsultancy.com
Wed, 18 May 2005 08:52:25 +0100


On Wednesday 18 May 2005 08:21, Jos=E9 Bollo wrote:
> Le mercredi 18 Mai 2005 09:08, Pascal Obry a =E9crit=A0:
> > For what it's worth, Ada too:
> >
> >     function compute_it_fast (x , y : in float)  return float;
> >     pragma Import (C, compute_it_fast);
>
> okay ada >=3D eiffel for that reliability ;-)

If you're allowed to use camlidl to generate C bindings for OCaml then you'=
ll=20
probably have an IDL description like:

  float compute_it_fast(float x, float y);

with an OCaml implementation like:

  external compute_it_fast : float -> float -> float =3D "%compute_it_fast"

and a call from the OCaml like:

  compute_it_fast 1.3 2.4

However, this is a very complicated subject in the context of OCaml and,=20
consequently, I think this should be avoided by the shootout.

=2D-=20
Dr Jon D Harrop, Flying Frog Consultancy Ltd.
Objective CAML for Scientists
http://www.ffconsultancy.com/products/ocaml_for_scientists