Skip to content

Patch for js_of_ocaml #8

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
diff --git a/compiler/lib/ocaml_compiler.ml b/compiler/lib/ocaml_compiler.ml
index 29b6c8f058..93de84e68d 100644
--- a/compiler/lib/ocaml_compiler.ml
+++ b/compiler/lib/ocaml_compiler.ml
@@ -32,7 +32,7 @@ let rec constant_of_const : _ -> Code.constant =
| Const_base (Const_int64 i) -> Int64 i
| Const_base (Const_nativeint i) -> Int (Int32.of_nativeint_warning_on_overflow i)
| Const_immstring s -> String s
- | Const_float_array sl ->
+ | Const_float_array sl | Const_block_array sl ->
let l = List.map ~f:(fun f -> Code.Float (float_of_string f)) sl in
Tuple (Obj.double_array_tag, Array.of_list l, Unknown)
| ((Const_pointer (i, _)) [@if BUCKLESCRIPT]) ->

40 changes: 40 additions & 0 deletions packages/js_of_ocaml/js_of_ocaml.3.10.0+flambda2/opam
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
opam-version: "2.0"
name: "js_of_ocaml"
version: "3.10.0"
synopsis: "Compiler from OCaml bytecode to JavaScript"
description:
"Js_of_ocaml is a compiler from OCaml bytecode to JavaScript. It makes it possible to run pure OCaml programs in JavaScript environment like browsers and Node.js"
maintainer: "Ocsigen team <[email protected]>"
authors: "Ocsigen team <[email protected]>"
license:
"GPL-2.0-or-later AND LGPL-2.1-or-later WITH OCaml-LGPL-linking-exception"
homepage: "https://ocsigen.github.io/js_of_ocaml"
doc: "https://ocsigen.github.io/js_of_ocaml"
bug-reports: "https://github.com/ocsigen/js_of_ocaml/issues"
depends: [
"dune" {>= "2.8"}
"ocaml" {>= "4.04"}
"js_of_ocaml-compiler" {= version}
"ppxlib" {>= "0.15"}
"uchar"
"num" {with-test}
"ppx_expect" {with-test}
"re" {>= "1.9.0" & with-test}
"odoc" {with-doc}
]
build: [
["dune" "subst"] {dev}
["dune" "build" "-p" name "-j" jobs "@install" "@doc" {with-doc}]
]
dev-repo: "git+https://github.com/ocsigen/js_of_ocaml.git"
url {
src:
"https://github.com/ocsigen/js_of_ocaml/releases/download/3.10.0/js_of_ocaml-3.10.0.tbz"
checksum: [
"sha256=7bfe95c283e30a53df9364555517aa4ea614876be566a86b33e6d0fefc4a6126"
"sha512=1815f0bfcea65a28082293756350a9365304584d3a19af0983e1498c6f8d7d25a751aec18560aa7b633b64b8adfb4417e9647cdf703bedcb7aaf316abf9a3243"
]
}
x-commit-hash: "41ca9c4aa3004e11803c1e49d3ad77ec799bf853"
patches: ["const_float_block.patch"]
extra-files: [ ["const_float_block.patch" "md5=2d6cba3dddd007b57b6e5bc96a588100"] ]