package zarith_stubs_js

All checked builds pass
  1. Overview
  2. Docs
Javascripts stubs for the Zarith library

Install

dune-project
 Dependency

Authors

Maintainers

Sources

v0.17.0.tar.gz
sha256=7301b11007bde9dc113f694059b1ba994232752655d926403d7664eff3ae143a

Description

This library contains no ocaml code, but instead implements all of the Zarith C stubs in Javascript for use in Js_of_ocaml

Added to opam-repository:

README

Zarith Stubs JS

Zarith is an OCaml library that implements common operations over arbitrary-precision integers and rationals. It is implemented via a C api that primarily calls out to Gnu Multiple Precision Arithmetic Library. Because of that C API, Zarith could not be compiled via Js_of_ocaml until now.

Zarith Stubs JS is a reimplementation of the native C functions in JavaScript. It makes extensive use of peterolson/BigInteger.js as a shim for browser BigInt functionality and also for the implementations of many numerical algorithms.

How to use it ?

In order to use zarith with js_of_ocaml, just provide the javascript runtime files to the js_of_ocaml compiler and use zarith as you would normally do.

In practice,

  • if you use dune to build your project, just add zarith_stubs_js as a library dependency.
  • if you don't use dune, you need to find a way to pass both biginteger.js and runtime.js files to the js_of_ocaml compiler command line.

Dependencies (2)

  1. dune >= "3.11.0"
  2. ocaml >= "5.1.0"

Dev Dependencies

None

Optional Dependencies

None

Used by (9)

  1. bignum >= "v0.17.0"
  2. bls12-381 >= "3.0.0"
  3. bls12-381-js >= "0.4.2"
  4. bls12-381-js-gen
  5. catala >= "0.3.0" & < "1.0.0~beta"
  6. data-encoding >= "0.5"
  7. integers_stubs_js
  8. polynomial >= "0.4.0"
  9. salto-analyzer

Conflicts

None

Build status

Results of building zarith_stubs_js with each compiler on check.ci.ocaml.org, run of against opam-repository 8a77e58. All results for this package.

Each result links to its build log. To keep crawlers from overloading the site, build logs require a GitHub sign-in (see ocurrent/opam-health-check). On your first log, GitHub asks you to “Authorize opam-health-check”, the OCurrent app that runs these checks; it sees only your public profile, not your repositories. The sign-in lasts 30 days.

Version OCaml 4.11 OCaml 4.14 OCaml 5.2 OCaml 5.4 OCaml 5.5
v0.17.0 (this version) n/a n/a good good good
v0.16.1 n/a good good good good
v0.15.0 good good good good good
  • good Package successfully built
  • partial One of the dependencies failed to build
  • bad Package failed to build
  • n/a Package is not available in this environment
  • internal Internal failure