Skip to content

Commit 3a8dbbf

Browse files
committed
internal tweak with better names
1 parent f1a6581 commit 3a8dbbf

File tree

8 files changed

+409
-420
lines changed

8 files changed

+409
-420
lines changed

jscomp/main/builtin_cmi_datasets.ml

Lines changed: 101 additions & 101 deletions
Large diffs are not rendered by default.

jscomp/runtime/js.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ end
132132
module MapperRt = Js_mapperRt
133133
module Internal = struct
134134
open Fn
135-
external unsafeInvariantApply : 'a -> 'a = "#full_apply"
135+
external opaqueFullApply : 'a -> 'a = "#full_apply"
136136

137137
(* Use opaque instead of [._n] to prevent some optimizations happening *)
138138
external run : 'a arity0 -> 'a = "#run"

jscomp/syntax/ast_literal.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ module Lid = struct
4848
(* TODO should be renamed in to {!Js.fn} *)
4949
(* TODO should be moved into {!Js.t} Later *)
5050
let js_internal : t = Ldot (Lident "Js", "Internal")
51-
let js_internal_full_apply : t = Ldot (js_internal, "unsafeInvariantApply")
51+
let js_internal_full_apply : t = Ldot (js_internal, "opaqueFullApply")
5252
let opaque : t = Ldot (js_internal, "opaque")
5353
let js_fn : t =
5454
Ldot (Lident "Js", "Fn")

jscomp/test/label_uncurry.ml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,6 @@ let h = fun [@bs] ~x:unit -> 3
1717

1818
let a = u1 u
1919

20-
(* let u1 (f : u) =
21-
Js.Internal.unsafeInvariantApply ((Js.Internal.run2 (f : u)) ~y:"x" ~x:2)
22-
*)
2320

2421

2522
type u0 = ?x:int -> y : string -> int [@bs]

jscomp/test/unsafe_full_apply_primitive.ml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,5 @@
11

22

3-
(* external unsafeInvariantApply : 'a -> 'a = "#full_apply"
4-
5-
6-
let f1 x = unsafeInvariantApply (x ())
7-
8-
9-
let f2 x y = unsafeInvariantApply (x y ()) *)
10-
113

124
let rec f = fun [@bs] a -> f a [@bs]
135

lib/4.06.1/unstable/js_compiler.ml

Lines changed: 102 additions & 102 deletions
Large diffs are not rendered by default.

lib/4.06.1/unstable/js_refmt_compiler.ml

Lines changed: 102 additions & 102 deletions
Large diffs are not rendered by default.

lib/4.06.1/whole_compiler.ml

Lines changed: 102 additions & 102 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)