From d46962bd235f181b59ce92c08ed53ea2e8a7ce49 Mon Sep 17 00:00:00 2001 From: Cristiano Calcagno Date: Mon, 22 Jul 2024 02:42:21 +0200 Subject: [PATCH] Remove opaque full apply entirely. Opaque full apply was still used in the case of partial application `foo(x, ...)`. With the last use gone, the `Js.Internal` module can be removed. One less piece of magic. --- jscomp/core/lam_convert.ml | 12 +- jscomp/frontend/ast_literal.ml | 4 - jscomp/frontend/ast_literal.mli | 2 - jscomp/ml/lambda.ml | 1 - jscomp/ml/lambda.mli | 1 - jscomp/ml/printlambda.ml | 2 - jscomp/ml/translcore.ml | 4 +- jscomp/ml/typecore.ml | 12 -- jscomp/others/js.res | 7 - jscomp/runtime/js.res | 7 - .../test/PartialApplicationNoRuntimeCurry.js | 3 +- jscomp/test/UncurriedAlways.js | 6 +- jscomp/test/bs_abstract_test.js | 2 +- jscomp/test/bs_list_test.js | 202 ++++++------------ jscomp/test/bs_map_set_dict_test.js | 12 +- jscomp/test/bs_poly_mutable_set_test.js | 80 ++----- jscomp/test/caml_format_test.js | 6 +- jscomp/test/digest_test.js | 8 +- jscomp/test/float_test.js | 6 +- jscomp/test/int64_mul_div_test.js | 8 +- jscomp/test/map_find_test.js | 40 ++-- jscomp/test/string_test.js | 4 +- jscomp/test/test_demo.js | 3 +- jscomp/test/test_google_closure.js | 4 +- lib/es6/js.js | 3 - lib/js/js.js | 3 - 26 files changed, 133 insertions(+), 309 deletions(-) diff --git a/jscomp/core/lam_convert.ml b/jscomp/core/lam_convert.ml index 1dba908f45..32d6b3fe7b 100644 --- a/jscomp/core/lam_convert.ml +++ b/jscomp/core/lam_convert.ml @@ -161,7 +161,7 @@ let unit = Lam.unit let lam_prim ~primitive:(p : Lambda.primitive) ~args loc : Lam.t = match p with | Pidentity -> Ext_list.singleton_exn args - | Puncurried_apply | Pccall _ -> assert false + | Pccall _ -> assert false | Prevapply -> assert false | Pdirapply -> assert false | Ploc _ -> assert false (* already compiled away here*) @@ -584,16 +584,6 @@ let convert (exports : Set_ident.t) (lam : Lambda.lambda) : may_depend may_depends (Lam_module_ident.of_ml ~dynamic_import id); assert (args = []); Lam.global_module ~dynamic_import id) - | Lprim - ( Puncurried_apply, - [ Lapply { ap_func; ap_args } ], - loc ) -> - let ap_func = convert_aux ap_func in - let ap_args = Ext_list.map ap_args convert_aux in - prim ~primitive:Pfull_apply ~args:(ap_func :: ap_args) loc - (* There may be some optimization opportunities here - for cases like `(fun [@bs] a b -> a + b ) 1 2 [@bs]` *) - | Lprim (Puncurried_apply, _, _) -> assert false | Lprim (primitive, args, loc) -> let args = Ext_list.map args (convert_aux ~dynamic_import) in lam_prim ~primitive ~args loc diff --git a/jscomp/frontend/ast_literal.ml b/jscomp/frontend/ast_literal.ml index 5ee13ec6aa..af71328945 100644 --- a/jscomp/frontend/ast_literal.ml +++ b/jscomp/frontend/ast_literal.ml @@ -49,10 +49,6 @@ module Lid = struct let type_bool : t = Lident "bool" (* use *predef* *) - (* TODO should be renamed in to {!Js.fn} *) - (* TODO should be moved into {!Js.t} Later *) - let js_internal : t = Ldot (Lident "Js", "Internal") - let js_oo : t = Lident "Js_OO" let js_meth_callback : t = Ldot (js_oo, "Callback") diff --git a/jscomp/frontend/ast_literal.mli b/jscomp/frontend/ast_literal.mli index 9e8d1cbdee..059b178dac 100644 --- a/jscomp/frontend/ast_literal.mli +++ b/jscomp/frontend/ast_literal.mli @@ -56,8 +56,6 @@ module Lid : sig val js_null_undefined : t val js_re_id : t - - val js_internal : t end type expression_lit = Parsetree.expression lit diff --git a/jscomp/ml/lambda.ml b/jscomp/ml/lambda.ml index 64dec28df1..8b7489402f 100644 --- a/jscomp/ml/lambda.ml +++ b/jscomp/ml/lambda.ml @@ -266,7 +266,6 @@ type primitive = | Pasrbint of boxed_integer | Pbintcomp of boxed_integer * comparison | Pctconst of compile_time_constant - | Puncurried_apply | Pcreate_extension of string and comparison = Ceq | Cneq | Clt | Cgt | Cle | Cge diff --git a/jscomp/ml/lambda.mli b/jscomp/ml/lambda.mli index 37452ed423..87125870c5 100644 --- a/jscomp/ml/lambda.mli +++ b/jscomp/ml/lambda.mli @@ -233,7 +233,6 @@ type primitive = | Pasrbint of boxed_integer | Pbintcomp of boxed_integer * comparison | Pctconst of compile_time_constant - | Puncurried_apply | Pcreate_extension of string and comparison = Ceq | Cneq | Clt | Cgt | Cle | Cge diff --git a/jscomp/ml/printlambda.ml b/jscomp/ml/printlambda.ml index dfb7203b30..4dc4e7705e 100644 --- a/jscomp/ml/printlambda.ml +++ b/jscomp/ml/printlambda.ml @@ -121,7 +121,6 @@ let print_taginfo ppf = function -> fprintf ppf "[%s]" (String.concat ";" (Array.to_list ss) ) let primitive ppf = function - | Puncurried_apply -> fprintf ppf "@app" | Pidentity -> fprintf ppf "id" | Pbytes_to_string -> fprintf ppf "bytes_to_string" | Pignore -> fprintf ppf "ignore" @@ -253,7 +252,6 @@ let primitive ppf = function | Pbintcomp(bi, Cge) -> print_boxed_integer ">=" ppf bi | Pcreate_extension s -> fprintf ppf "extension[%s]" s let name_of_primitive = function - | Puncurried_apply -> "Puncurried_apply" | Pidentity -> "Pidentity" | Pbytes_to_string -> "Pbytes_to_string" | Pignore -> "Pignore" diff --git a/jscomp/ml/translcore.ml b/jscomp/ml/translcore.ml index 6723662971..a5733de523 100644 --- a/jscomp/ml/translcore.ml +++ b/jscomp/ml/translcore.ml @@ -422,7 +422,6 @@ let primitives_table = ("%int64_to_int32", Pcvtbint (Pint64, Pint32)); ("%int64_of_bigint", Pcvtbint (Pbigint, Pint64)); ("%int64_to_bigint", Pcvtbint (Pint64, Pbigint)); - ("%uncurried_apply", Puncurried_apply); ] let find_primitive prim_name = Hashtbl.find primitives_table prim_name @@ -1101,11 +1100,10 @@ and transl_apply ?(inlined = Default_inline) ?(uncurried_partial_application=Non let extra_args = Ext_list.map extra_ids (fun id -> Lvar id) in let ap_args = args @ extra_args in let l0 = Lapply { ap_func = lam; ap_args; ap_inlined = inlined; ap_loc = loc } in - let l1 = Lprim (Puncurried_apply, [l0], loc) in Lfunction { params = List.rev_append !none_ids extra_ids ; - body = l1; + body = l0; attr = default_function_attribute; loc; } diff --git a/jscomp/ml/typecore.ml b/jscomp/ml/typecore.ml index 5fcb3d7288..7a76507dc4 100644 --- a/jscomp/ml/typecore.ml +++ b/jscomp/ml/typecore.ml @@ -2153,18 +2153,6 @@ and type_expect_ ?type_clash_context ?in_function ?(recarg=Rejected) env sexp ty end_def (); unify_var env (newvar()) funct.exp_type; - let mk_exp ?(loc=Location.none) exp_desc exp_type = - { exp_desc; - exp_loc = loc; exp_extra = []; - exp_type; - exp_attributes = []; - exp_env = env } in - let _apply_internal name e = - let lid:Longident.t = Ldot (Ldot (Lident "Js", "Internal"), name) in - let (path, desc) = Env.lookup_value lid env in - let id = mk_exp (Texp_ident(path, {txt=lid; loc=Location.none}, desc)) desc.val_type in - mk_exp ~loc:e.exp_loc (Texp_apply(id, [(Nolabel, Some e)])) e.exp_type in - let mk_apply funct args = rue { exp_desc = Texp_apply(funct, args); diff --git a/jscomp/others/js.res b/jscomp/others/js.res index 13e64195f2..c23e8ccccc 100644 --- a/jscomp/others/js.res +++ b/jscomp/others/js.res @@ -77,13 +77,6 @@ Prefer `Js.Array2` over `Js.Array`, `Js.String2` over `Js.String`, etc. The latt /** JS object type */ type t<'a> = {..} as 'a -module Internal = { - external opaqueFullApply: 'a => 'a = "%uncurried_apply" - - /* Use opaque instead of [._n] to prevent some optimizations happening */ - external run: ((. unit) => 'a) => 'a = "#run" -} - /** Nullable value of this type can be either null or 'a. This type is equivalent to Js.Null.t. */ diff --git a/jscomp/runtime/js.res b/jscomp/runtime/js.res index aebbff2f14..a0432c98fc 100644 --- a/jscomp/runtime/js.res +++ b/jscomp/runtime/js.res @@ -77,13 +77,6 @@ Prefer `Js.Array2` over `Js.Array`, `Js.String2` over `Js.String`, etc. The latt /** JS object type */ type t<'a> = {..} as 'a -module Internal = { - external opaqueFullApply: 'a => 'a = "%uncurried_apply" - - /* Use opaque instead of [._n] to prevent some optimizations happening */ - external run: ((. unit) => 'a) => 'a = "#run" -} - /** Nullable value of this type can be either null or 'a. This type is equivalent to Js.Null.t. */ diff --git a/jscomp/test/PartialApplicationNoRuntimeCurry.js b/jscomp/test/PartialApplicationNoRuntimeCurry.js index 89cd1695ef..f96fa7badd 100644 --- a/jscomp/test/PartialApplicationNoRuntimeCurry.js +++ b/jscomp/test/PartialApplicationNoRuntimeCurry.js @@ -1,6 +1,7 @@ // Generated by ReScript, PLEASE EDIT WITH CARE 'use strict'; +let Curry = require("../../lib/js/curry.js"); function add(x) { return function (y, z) { @@ -11,7 +12,7 @@ function add(x) { function f(u) { let f$1 = add(u); return function (extra) { - return f$1(1, extra); + return Curry._2(f$1, 1, extra); }; } diff --git a/jscomp/test/UncurriedAlways.js b/jscomp/test/UncurriedAlways.js index 2a4cdf49df..24c3fa3fba 100644 --- a/jscomp/test/UncurriedAlways.js +++ b/jscomp/test/UncurriedAlways.js @@ -73,7 +73,11 @@ function ptl$1(none, extra) { ]; } -let a1 = ptl$1("x", "z"); +let a1 = [ + "x", + "y", + "z" +]; console.log("a1:", a1); diff --git a/jscomp/test/bs_abstract_test.js b/jscomp/test/bs_abstract_test.js index e30aa9e898..8c745a5e94 100644 --- a/jscomp/test/bs_abstract_test.js +++ b/jscomp/test/bs_abstract_test.js @@ -23,7 +23,7 @@ function uf(u) { function uf1(u) { return function (extra) { - return u.y1(1, extra); + return Curry._2(u.y1, 1, extra); }; } diff --git a/jscomp/test/bs_list_test.js b/jscomp/test/bs_list_test.js index 174aa0efc9..3d5f260957 100644 --- a/jscomp/test/bs_list_test.js +++ b/jscomp/test/bs_list_test.js @@ -110,11 +110,7 @@ eq("File \"bs_list_test.res\", line 33, characters 5-12", Belt_List.getBy({ return x % 5 === 0; })), undefined); -function $eq$tilde(extra, extra$1) { - return eq("FLATTEN", extra, extra$1); -} - -$eq$tilde(Belt_List.flatten({ +eq("FLATTEN", Belt_List.flatten({ hd: { hd: 1, tl: /* [] */0 @@ -163,9 +159,9 @@ $eq$tilde(Belt_List.flatten({ } }); -$eq$tilde(Belt_List.flatten(/* [] */0), /* [] */0); +eq("FLATTEN", Belt_List.flatten(/* [] */0), /* [] */0); -$eq$tilde(Belt_List.flatten({ +eq("FLATTEN", Belt_List.flatten({ hd: /* [] */0, tl: { hd: /* [] */0, @@ -203,11 +199,7 @@ $eq$tilde(Belt_List.flatten({ } }); -function $eq$tilde$1(extra, extra$1) { - return eq("CONCATMANY", extra, extra$1); -} - -$eq$tilde$1(Belt_List.concatMany([ +eq("CONCATMANY", Belt_List.concatMany([ { hd: 1, tl: /* [] */0 @@ -247,9 +239,9 @@ $eq$tilde$1(Belt_List.concatMany([ } }); -$eq$tilde$1(Belt_List.concatMany([]), /* [] */0); +eq("CONCATMANY", Belt_List.concatMany([]), /* [] */0); -$eq$tilde$1(Belt_List.concatMany([ +eq("CONCATMANY", Belt_List.concatMany([ /* [] */0, /* [] */0, { @@ -276,7 +268,7 @@ $eq$tilde$1(Belt_List.concatMany([ } }); -$eq$tilde$1(Belt_List.concatMany([ +eq("CONCATMANY", Belt_List.concatMany([ /* [] */0, /* [] */0, { @@ -309,7 +301,7 @@ $eq$tilde$1(Belt_List.concatMany([ } }); -$eq$tilde$1(Belt_List.concatMany([{ +eq("CONCATMANY", Belt_List.concatMany([{ hd: 1, tl: { hd: 2, @@ -339,11 +331,7 @@ eq("File \"bs_list_test.res\", line 66, characters 2-9", Belt_List.toArray(Belt_ return i; })))); -function $eq$tilde$2(extra, extra$1) { - return eq("APPEND", extra, extra$1); -} - -$eq$tilde$2(Belt_List.concat({ +eq("APPEND", Belt_List.concat({ hd: 1, tl: /* [] */0 }, /* [] */0), { @@ -351,7 +339,7 @@ $eq$tilde$2(Belt_List.concat({ tl: /* [] */0 }); -$eq$tilde$2(Belt_List.concat(/* [] */0, { +eq("APPEND", Belt_List.concat(/* [] */0, { hd: 1, tl: /* [] */0 }), { @@ -359,11 +347,7 @@ $eq$tilde$2(Belt_List.concat(/* [] */0, { tl: /* [] */0 }); -function $eq$tilde$3(extra, extra$1) { - return eq("ZIP", extra, extra$1); -} - -$eq$tilde$3(Belt_List.zip({ +eq("ZIP", Belt_List.zip({ hd: 1, tl: { hd: 2, @@ -392,14 +376,14 @@ $eq$tilde$3(Belt_List.zip({ } }); -$eq$tilde$3(Belt_List.zip(/* [] */0, { +eq("ZIP", Belt_List.zip(/* [] */0, { hd: 1, tl: /* [] */0 }), /* [] */0); -$eq$tilde$3(Belt_List.zip(/* [] */0, /* [] */0), /* [] */0); +eq("ZIP", Belt_List.zip(/* [] */0, /* [] */0), /* [] */0); -$eq$tilde$3(Belt_List.zip({ +eq("ZIP", Belt_List.zip({ hd: 1, tl: { hd: 2, @@ -410,7 +394,7 @@ $eq$tilde$3(Belt_List.zip({ } }, /* [] */0), /* [] */0); -$eq$tilde$3(Belt_List.zip({ +eq("ZIP", Belt_List.zip({ hd: 1, tl: { hd: 2, @@ -456,11 +440,7 @@ function evenIndex(_x, i) { return i % 2 === 0; } -function $eq$tilde$4(extra, extra$1) { - return eq("PARTITION", extra, extra$1); -} - -$eq$tilde$4(Belt_List.partition({ +eq("PARTITION", Belt_List.partition({ hd: 1, tl: { hd: 2, @@ -501,7 +481,7 @@ $eq$tilde$4(Belt_List.partition({ } ]); -$eq$tilde$4(Belt_List.partition({ +eq("PARTITION", Belt_List.partition({ hd: 2, tl: { hd: 2, @@ -530,7 +510,7 @@ $eq$tilde$4(Belt_List.partition({ /* [] */0 ]); -$eq$tilde$4(Belt_List.partition({ +eq("PARTITION", Belt_List.partition({ hd: 2, tl: { hd: 2, @@ -561,21 +541,17 @@ $eq$tilde$4(Belt_List.partition({ } ]); -$eq$tilde$4(Belt_List.partition(/* [] */0, mod2), [ +eq("PARTITION", Belt_List.partition(/* [] */0, mod2), [ /* [] */0, /* [] */0 ]); -function $eq$tilde$5(extra, extra$1) { - return eq("UNZIP", extra, extra$1); -} - -$eq$tilde$5(Belt_List.unzip(/* [] */0), [ +eq("UNZIP", Belt_List.unzip(/* [] */0), [ /* [] */0, /* [] */0 ]); -$eq$tilde$5(Belt_List.unzip({ +eq("UNZIP", Belt_List.unzip({ hd: [ 1, 2 @@ -592,7 +568,7 @@ $eq$tilde$5(Belt_List.unzip({ } ]); -$eq$tilde$5(Belt_List.unzip({ +eq("UNZIP", Belt_List.unzip({ hd: [ 1, 2 @@ -621,11 +597,7 @@ $eq$tilde$5(Belt_List.unzip({ } ]); -function $eq$tilde$6(extra, extra$1) { - return eq("FILTER", extra, extra$1); -} - -$eq$tilde$6(Belt_List.keep({ +eq("FILTER", Belt_List.keep({ hd: 1, tl: { hd: 2, @@ -645,7 +617,7 @@ $eq$tilde$6(Belt_List.keep({ } }); -$eq$tilde$6(Belt_List.keep({ +eq("FILTER", Belt_List.keep({ hd: 1, tl: { hd: 3, @@ -656,9 +628,9 @@ $eq$tilde$6(Belt_List.keep({ } }, mod2), /* [] */0); -$eq$tilde$6(Belt_List.keep(/* [] */0, mod2), /* [] */0); +eq("FILTER", Belt_List.keep(/* [] */0, mod2), /* [] */0); -$eq$tilde$6(Belt_List.keep({ +eq("FILTER", Belt_List.keep({ hd: 2, tl: { hd: 2, @@ -690,13 +662,9 @@ $eq$tilde$6(Belt_List.keep({ } }); -function $eq$tilde$7(extra, extra$1) { - return eq("FILTER2", extra, extra$1); -} - -$eq$tilde$7(Belt_List.keepWithIndex(/* [] */0, evenIndex), /* [] */0); +eq("FILTER2", Belt_List.keepWithIndex(/* [] */0, evenIndex), /* [] */0); -$eq$tilde$7(Belt_List.keepWithIndex({ +eq("FILTER2", Belt_List.keepWithIndex({ hd: 1, tl: { hd: 2, @@ -716,7 +684,7 @@ $eq$tilde$7(Belt_List.keepWithIndex({ } }); -$eq$tilde$7(Belt_List.keepWithIndex({ +eq("FILTER2", Belt_List.keepWithIndex({ hd: 0, tl: { hd: 1, @@ -758,11 +726,7 @@ function id(x) { return x; } -function $eq$tilde$8(extra, extra$1) { - return eq("MAP", extra, extra$1); -} - -$eq$tilde$8(Belt_List.map(Belt_List.makeBy(5, id), (function (x) { +eq("MAP", Belt_List.map(Belt_List.makeBy(5, id), (function (x) { return (x << 1); })), { hd: 0, @@ -781,9 +745,9 @@ $eq$tilde$8(Belt_List.map(Belt_List.makeBy(5, id), (function (x) { } }); -$eq$tilde$8(Belt_List.map(/* [] */0, id), /* [] */0); +eq("MAP", Belt_List.map(/* [] */0, id), /* [] */0); -$eq$tilde$8(Belt_List.map({ +eq("MAP", Belt_List.map({ hd: 1, tl: /* [] */0 }, (function (x) { @@ -801,29 +765,25 @@ let length_10_id = Belt_List.makeBy(10, id); let length_8_id = Belt_List.makeBy(8, id); -function $eq$tilde$9(extra, extra$1) { - return eq("MAP2", extra, extra$1); -} - let d = Belt_List.makeBy(10, (function (x) { return (x << 1); })); -$eq$tilde$9(Belt_List.zipBy(length_10_id, length_10_id, add), d); +eq("MAP2", Belt_List.zipBy(length_10_id, length_10_id, add), d); -$eq$tilde$9(Belt_List.zipBy(/* [] */0, { +eq("MAP2", Belt_List.zipBy(/* [] */0, { hd: 1, tl: /* [] */0 }, add), /* [] */0); -$eq$tilde$9(Belt_List.zipBy({ +eq("MAP2", Belt_List.zipBy({ hd: 1, tl: /* [] */0 }, /* [] */0, add), /* [] */0); -$eq$tilde$9(Belt_List.zipBy(/* [] */0, /* [] */0, add), /* [] */0); +eq("MAP2", Belt_List.zipBy(/* [] */0, /* [] */0, add), /* [] */0); -$eq$tilde$9(Belt_List.zipBy(length_10_id, length_10_id, add), Belt_List.concat(Belt_List.map(length_8_id, (function (x) { +eq("MAP2", Belt_List.zipBy(length_10_id, length_10_id, add), Belt_List.concat(Belt_List.map(length_8_id, (function (x) { return (x << 1); })), { hd: 16, @@ -833,11 +793,11 @@ $eq$tilde$9(Belt_List.zipBy(length_10_id, length_10_id, add), Belt_List.concat(B } })); -$eq$tilde$9(Belt_List.zipBy(length_10_id, length_8_id, add), Belt_List.mapWithIndex(length_8_id, (function (i, x) { +eq("MAP2", Belt_List.zipBy(length_10_id, length_8_id, add), Belt_List.mapWithIndex(length_8_id, (function (i, x) { return i + x | 0; }))); -$eq$tilde$9(Belt_List.reverse(Belt_List.mapReverse2(length_10_id, length_10_id, add)), Belt_List.map(length_10_id, (function (x) { +eq("MAP2", Belt_List.reverse(Belt_List.mapReverse2(length_10_id, length_10_id, add)), Belt_List.map(length_10_id, (function (x) { return (x << 1); }))); @@ -845,9 +805,9 @@ let xs = Belt_List.reverse(Belt_List.mapReverse2(length_8_id, length_10_id, add) eq("File \"bs_list_test.res\", line 163, characters 5-12", Belt_List.length(xs), 8); -$eq$tilde$9(xs, Belt_List.zipBy(length_10_id, length_8_id, add)); +eq("MAP2", xs, Belt_List.zipBy(length_10_id, length_8_id, add)); -$eq$tilde$9(Belt_List.mapReverse2({ +eq("MAP2", Belt_List.mapReverse2({ hd: 1, tl: { hd: 2, @@ -872,11 +832,7 @@ $eq$tilde$9(Belt_List.mapReverse2({ } }); -function $eq$tilde$10(extra, extra$1) { - return eq("TAKE", extra, extra$1); -} - -$eq$tilde$10(Belt_List.take({ +eq("TAKE", Belt_List.take({ hd: 1, tl: { hd: 2, @@ -893,9 +849,9 @@ $eq$tilde$10(Belt_List.take({ } }); -$eq$tilde$10(Belt_List.take(/* [] */0, 1), undefined); +eq("TAKE", Belt_List.take(/* [] */0, 1), undefined); -$eq$tilde$10(Belt_List.take({ +eq("TAKE", Belt_List.take({ hd: 1, tl: { hd: 2, @@ -903,7 +859,7 @@ $eq$tilde$10(Belt_List.take({ } }, 3), undefined); -$eq$tilde$10(Belt_List.take({ +eq("TAKE", Belt_List.take({ hd: 1, tl: { hd: 2, @@ -917,19 +873,15 @@ $eq$tilde$10(Belt_List.take({ } }); -$eq$tilde$10(Belt_List.take(length_10_id, 8), length_8_id); +eq("TAKE", Belt_List.take(length_10_id, 8), length_8_id); -$eq$tilde$10(Belt_List.take(length_10_id, 0), /* [] */0); +eq("TAKE", Belt_List.take(length_10_id, 0), /* [] */0); -$eq$tilde$10(Belt_List.take(length_8_id, -2), undefined); +eq("TAKE", Belt_List.take(length_8_id, -2), undefined); -function $eq$tilde$11(extra, extra$1) { - return eq("DROP", extra, extra$1); -} +eq("DROP", Belt_List.drop(length_10_id, 10), /* [] */0); -$eq$tilde$11(Belt_List.drop(length_10_id, 10), /* [] */0); - -$eq$tilde$11(Belt_List.drop(length_10_id, 8), { +eq("DROP", Belt_List.drop(length_10_id, 8), { hd: 8, tl: { hd: 9, @@ -937,26 +889,22 @@ $eq$tilde$11(Belt_List.drop(length_10_id, 8), { } }); -$eq$tilde$11(Belt_List.drop(length_10_id, 0), length_10_id); - -$eq$tilde$11(Belt_List.drop(length_8_id, -1), undefined); +eq("DROP", Belt_List.drop(length_10_id, 0), length_10_id); -function $eq$tilde$12(extra, extra$1) { - return eq("SPLIT", extra, extra$1); -} +eq("DROP", Belt_List.drop(length_8_id, -1), undefined); let a = Belt_List.makeBy(5, id); -$eq$tilde$12(Belt_List.splitAt(/* [] */0, 1), undefined); +eq("SPLIT", Belt_List.splitAt(/* [] */0, 1), undefined); -$eq$tilde$12(Belt_List.splitAt(a, 6), undefined); +eq("SPLIT", Belt_List.splitAt(a, 6), undefined); -$eq$tilde$12(Belt_List.splitAt(a, 5), [ +eq("SPLIT", Belt_List.splitAt(a, 5), [ a, /* [] */0 ]); -$eq$tilde$12(Belt_List.splitAt(a, 4), [ +eq("SPLIT", Belt_List.splitAt(a, 4), [ { hd: 0, tl: { @@ -976,7 +924,7 @@ $eq$tilde$12(Belt_List.splitAt(a, 4), [ } ]); -$eq$tilde$12(Belt_List.splitAt(a, 3), [ +eq("SPLIT", Belt_List.splitAt(a, 3), [ { hd: 0, tl: { @@ -996,7 +944,7 @@ $eq$tilde$12(Belt_List.splitAt(a, 3), [ } ]); -$eq$tilde$12(Belt_List.splitAt(a, 2), [ +eq("SPLIT", Belt_List.splitAt(a, 2), [ { hd: 0, tl: { @@ -1016,7 +964,7 @@ $eq$tilde$12(Belt_List.splitAt(a, 2), [ } ]); -$eq$tilde$12(Belt_List.splitAt(a, 1), [ +eq("SPLIT", Belt_List.splitAt(a, 1), [ { hd: 0, tl: /* [] */0 @@ -1036,21 +984,17 @@ $eq$tilde$12(Belt_List.splitAt(a, 1), [ } ]); -$eq$tilde$12(Belt_List.splitAt(a, 0), [ +eq("SPLIT", Belt_List.splitAt(a, 0), [ /* [] */0, a ]); -$eq$tilde$12(Belt_List.splitAt(a, -1), undefined); +eq("SPLIT", Belt_List.splitAt(a, -1), undefined); function succx(x) { return x + 1 | 0; } -function $eq$tilde$13(extra, extra$1) { - return eq("REMOVEASSOQ", extra, extra$1); -} - function eqx(x, y) { return x === y; } @@ -1121,7 +1065,7 @@ b("File \"bs_list_test.res\", line 207, characters 4-11", Belt_List.hasAssoc({ return (x + 1 | 0) === y; }))); -$eq$tilde$13(Belt_List.removeAssoc({ +eq("REMOVEASSOQ", Belt_List.removeAssoc({ hd: [ 1, "1" @@ -1155,7 +1099,7 @@ $eq$tilde$13(Belt_List.removeAssoc({ } }); -$eq$tilde$13(Belt_List.removeAssoc({ +eq("REMOVEASSOQ", Belt_List.removeAssoc({ hd: [ 1, "1" @@ -1189,7 +1133,7 @@ $eq$tilde$13(Belt_List.removeAssoc({ } }); -$eq$tilde$13(Belt_List.removeAssoc({ +eq("REMOVEASSOQ", Belt_List.removeAssoc({ hd: [ 1, "1" @@ -1223,7 +1167,7 @@ $eq$tilde$13(Belt_List.removeAssoc({ } }); -$eq$tilde$13(Belt_List.removeAssoc({ +eq("REMOVEASSOQ", Belt_List.removeAssoc({ hd: [ 1, "1" @@ -1263,7 +1207,7 @@ $eq$tilde$13(Belt_List.removeAssoc({ } }); -$eq$tilde$13(Belt_List.removeAssoc({ +eq("REMOVEASSOQ", Belt_List.removeAssoc({ hd: [ 1, "1" @@ -1295,7 +1239,7 @@ $eq$tilde$13(Belt_List.removeAssoc({ } }); -$eq$tilde$13(Belt_List.removeAssoc({ +eq("REMOVEASSOQ", Belt_List.removeAssoc({ hd: [ 1, "1" @@ -1327,7 +1271,7 @@ $eq$tilde$13(Belt_List.removeAssoc({ } }); -$eq$tilde$13(Belt_List.removeAssoc({ +eq("REMOVEASSOQ", Belt_List.removeAssoc({ hd: [ 1, "1" @@ -1359,7 +1303,7 @@ $eq$tilde$13(Belt_List.removeAssoc({ } }); -$eq$tilde$13(Belt_List.removeAssoc(/* [] */0, 2, eqx), /* [] */0); +eq("REMOVEASSOQ", Belt_List.removeAssoc(/* [] */0, 2, eqx), /* [] */0); let ll = { hd: [ @@ -2350,15 +2294,11 @@ makeTest(2); makeTest(3); -function $eq$tilde$14(extra, extra$1) { - return eq("SORT", extra, extra$1); -} - function cmp(a, b) { return a - b | 0; } -$eq$tilde$14(Belt_List.sort({ +eq("SORT", Belt_List.sort({ hd: 5, tl: { hd: 4, @@ -2384,7 +2324,7 @@ $eq$tilde$14(Belt_List.sort({ } }); -$eq$tilde$14(Belt_List.sort({ +eq("SORT", Belt_List.sort({ hd: 3, tl: { hd: 9, diff --git a/jscomp/test/bs_map_set_dict_test.js b/jscomp/test/bs_map_set_dict_test.js index f4b7b41de7..0f22228a21 100644 --- a/jscomp/test/bs_map_set_dict_test.js +++ b/jscomp/test/bs_map_set_dict_test.js @@ -112,14 +112,12 @@ function $eq$tilde(a, b) { }; } -let none = Belt_Array.map(Array_data_util.randomRange(0, 39), (function (x) { +let u0 = Belt_Map.fromArray(Belt_Array.map(Array_data_util.randomRange(0, 39), (function (x) { return [ x, x ]; -})); - -let u0 = Belt_Map.fromArray(none, Icmp); +})), Icmp); let u1 = Belt_Map.set(u0, 39, 120); @@ -153,14 +151,12 @@ eq("File \"bs_map_set_dict_test.res\", line 84, characters 5-12", Belt_Map.get(u eq("File \"bs_map_set_dict_test.res\", line 85, characters 5-12", Belt_Map.get(u1, 39), 120); -let none$1 = Belt_Array.makeByAndShuffle(10000, (function (x) { +let u = Belt_Map.fromArray(Belt_Array.makeByAndShuffle(10000, (function (x) { return [ x, x ]; -})); - -let u = Belt_Map.fromArray(none$1, Icmp); +})), Icmp); eq("File \"bs_map_set_dict_test.res\", line 90, characters 5-12", Belt_Array.makeBy(10000, (function (x) { return [ diff --git a/jscomp/test/bs_poly_mutable_set_test.js b/jscomp/test/bs_poly_mutable_set_test.js index 555faffc53..33a00591d1 100644 --- a/jscomp/test/bs_poly_mutable_set_test.js +++ b/jscomp/test/bs_poly_mutable_set_test.js @@ -39,9 +39,7 @@ function empty() { }; } -let none = Array_data_util.range(0, 30); - -let u = Belt_MutableSet.fromArray(none, IntCmp); +let u = Belt_MutableSet.fromArray(Array_data_util.range(0, 30), IntCmp); b("File \"bs_poly_mutable_set_test.res\", line 16, characters 4-11", Belt_MutableSet.removeCheck(u, 0)); @@ -117,9 +115,7 @@ Belt_MutableSet.removeMany(u, Array_data_util.randomRange(10000, 30000)); b("File \"bs_poly_mutable_set_test.res\", line 54, characters 4-11", Belt_MutableSet.isEmpty(u)); -let none$1 = Array_data_util.randomRange(1000, 2000); - -let v = Belt_MutableSet.fromArray(none$1, IntCmp); +let v = Belt_MutableSet.fromArray(Array_data_util.randomRange(1000, 2000), IntCmp); let bs = Belt_Array.map(Array_data_util.randomRange(500, 1499), (function (x) { return Belt_MutableSet.removeCheck(v, x); @@ -236,48 +232,26 @@ b("File \"bs_poly_mutable_set_test.res\", line 104, characters 4-11", Belt_Mutab b("File \"bs_poly_mutable_set_test.res\", line 105, characters 4-11", Belt_MutableSet.isEmpty(Belt_MutableSet.intersect(aa$1, bb$1))); -let none$2 = Array_data_util.randomRange(0, 100); - -let aa$2 = Belt_MutableSet.fromArray(none$2, IntCmp); - -let none$3 = Array_data_util.randomRange(40, 120); +let aa$2 = Belt_MutableSet.fromArray(Array_data_util.randomRange(0, 100), IntCmp); -let bb$2 = Belt_MutableSet.fromArray(none$3, IntCmp); +let bb$2 = Belt_MutableSet.fromArray(Array_data_util.randomRange(40, 120), IntCmp); let cc = Belt_MutableSet.union(aa$2, bb$2); -let none$4 = Array_data_util.randomRange(0, 120); - -b("File \"bs_poly_mutable_set_test.res\", line 115, characters 4-11", Belt_MutableSet.eq(cc, Belt_MutableSet.fromArray(none$4, IntCmp))); - -let none$5 = Array_data_util.randomRange(0, 20); - -let none$6 = Array_data_util.randomRange(21, 40); +b("File \"bs_poly_mutable_set_test.res\", line 115, characters 4-11", Belt_MutableSet.eq(cc, Belt_MutableSet.fromArray(Array_data_util.randomRange(0, 120), IntCmp))); -let none$7 = Array_data_util.randomRange(0, 40); - -b("File \"bs_poly_mutable_set_test.res\", line 118, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.union(Belt_MutableSet.fromArray(none$5, IntCmp), Belt_MutableSet.fromArray(none$6, IntCmp)), Belt_MutableSet.fromArray(none$7, IntCmp))); +b("File \"bs_poly_mutable_set_test.res\", line 118, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.union(Belt_MutableSet.fromArray(Array_data_util.randomRange(0, 20), IntCmp), Belt_MutableSet.fromArray(Array_data_util.randomRange(21, 40), IntCmp)), Belt_MutableSet.fromArray(Array_data_util.randomRange(0, 40), IntCmp))); let dd = Belt_MutableSet.intersect(aa$2, bb$2); -let none$8 = Array_data_util.randomRange(40, 100); - -b("File \"bs_poly_mutable_set_test.res\", line 122, characters 4-11", Belt_MutableSet.eq(dd, Belt_MutableSet.fromArray(none$8, IntCmp))); - -let none$9 = Array_data_util.randomRange(0, 20); +b("File \"bs_poly_mutable_set_test.res\", line 122, characters 4-11", Belt_MutableSet.eq(dd, Belt_MutableSet.fromArray(Array_data_util.randomRange(40, 100), IntCmp))); -let none$10 = Array_data_util.randomRange(21, 40); - -b("File \"bs_poly_mutable_set_test.res\", line 124, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.intersect(Belt_MutableSet.fromArray(none$9, IntCmp), Belt_MutableSet.fromArray(none$10, IntCmp)), { +b("File \"bs_poly_mutable_set_test.res\", line 124, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.intersect(Belt_MutableSet.fromArray(Array_data_util.randomRange(0, 20), IntCmp), Belt_MutableSet.fromArray(Array_data_util.randomRange(21, 40), IntCmp)), { cmp: IntCmp.cmp, data: undefined })); -let none$11 = Array_data_util.randomRange(21, 40); - -let none$12 = Array_data_util.randomRange(0, 20); - -b("File \"bs_poly_mutable_set_test.res\", line 128, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.intersect(Belt_MutableSet.fromArray(none$11, IntCmp), Belt_MutableSet.fromArray(none$12, IntCmp)), { +b("File \"bs_poly_mutable_set_test.res\", line 128, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.intersect(Belt_MutableSet.fromArray(Array_data_util.randomRange(21, 40), IntCmp), Belt_MutableSet.fromArray(Array_data_util.randomRange(0, 20), IntCmp)), { cmp: IntCmp.cmp, data: undefined })); @@ -301,41 +275,17 @@ b("File \"bs_poly_mutable_set_test.res\", line 131, characters 4-11", Belt_Mutab 5 ], IntCmp))); -let none$13 = Array_data_util.randomRange(0, 39); - -b("File \"bs_poly_mutable_set_test.res\", line 132, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.diff(aa$2, bb$2), Belt_MutableSet.fromArray(none$13, IntCmp))); - -let none$14 = Array_data_util.randomRange(101, 120); - -b("File \"bs_poly_mutable_set_test.res\", line 133, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.diff(bb$2, aa$2), Belt_MutableSet.fromArray(none$14, IntCmp))); - -let none$15 = Array_data_util.randomRange(21, 40); - -let none$16 = Array_data_util.randomRange(0, 20); - -let none$17 = Array_data_util.randomRange(21, 40); - -b("File \"bs_poly_mutable_set_test.res\", line 135, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.diff(Belt_MutableSet.fromArray(none$15, IntCmp), Belt_MutableSet.fromArray(none$16, IntCmp)), Belt_MutableSet.fromArray(none$17, IntCmp))); - -let none$18 = Array_data_util.randomRange(0, 20); - -let none$19 = Array_data_util.randomRange(21, 40); - -let none$20 = Array_data_util.randomRange(0, 20); - -b("File \"bs_poly_mutable_set_test.res\", line 142, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.diff(Belt_MutableSet.fromArray(none$18, IntCmp), Belt_MutableSet.fromArray(none$19, IntCmp)), Belt_MutableSet.fromArray(none$20, IntCmp))); - -let none$21 = Array_data_util.randomRange(0, 20); +b("File \"bs_poly_mutable_set_test.res\", line 132, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.diff(aa$2, bb$2), Belt_MutableSet.fromArray(Array_data_util.randomRange(0, 39), IntCmp))); -let none$22 = Array_data_util.randomRange(0, 40); +b("File \"bs_poly_mutable_set_test.res\", line 133, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.diff(bb$2, aa$2), Belt_MutableSet.fromArray(Array_data_util.randomRange(101, 120), IntCmp))); -let none$23 = Array_data_util.randomRange(0, -1); +b("File \"bs_poly_mutable_set_test.res\", line 135, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.diff(Belt_MutableSet.fromArray(Array_data_util.randomRange(21, 40), IntCmp), Belt_MutableSet.fromArray(Array_data_util.randomRange(0, 20), IntCmp)), Belt_MutableSet.fromArray(Array_data_util.randomRange(21, 40), IntCmp))); -b("File \"bs_poly_mutable_set_test.res\", line 150, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.diff(Belt_MutableSet.fromArray(none$21, IntCmp), Belt_MutableSet.fromArray(none$22, IntCmp)), Belt_MutableSet.fromArray(none$23, IntCmp))); +b("File \"bs_poly_mutable_set_test.res\", line 142, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.diff(Belt_MutableSet.fromArray(Array_data_util.randomRange(0, 20), IntCmp), Belt_MutableSet.fromArray(Array_data_util.randomRange(21, 40), IntCmp)), Belt_MutableSet.fromArray(Array_data_util.randomRange(0, 20), IntCmp))); -let none$24 = Array_data_util.randomRange(0, 1000); +b("File \"bs_poly_mutable_set_test.res\", line 150, characters 4-11", Belt_MutableSet.eq(Belt_MutableSet.diff(Belt_MutableSet.fromArray(Array_data_util.randomRange(0, 20), IntCmp), Belt_MutableSet.fromArray(Array_data_util.randomRange(0, 40), IntCmp)), Belt_MutableSet.fromArray(Array_data_util.randomRange(0, -1), IntCmp))); -let a0 = Belt_MutableSet.fromArray(none$24, IntCmp); +let a0 = Belt_MutableSet.fromArray(Array_data_util.randomRange(0, 1000), IntCmp); let a1 = Belt_MutableSet.keep(a0, (function (x) { return x % 2 === 0; diff --git a/jscomp/test/caml_format_test.js b/jscomp/test/caml_format_test.js index 6fee11065f..f184d33bb2 100644 --- a/jscomp/test/caml_format_test.js +++ b/jscomp/test/caml_format_test.js @@ -423,7 +423,7 @@ let of_string_data = [ ] ]; -let extra = Pervasives.$at(suites, Pervasives.$at($$Array.to_list($$Array.mapi((function (i, param) { +Mt.from_pair_suites("Caml_format_test", Pervasives.$at(suites, Pervasives.$at($$Array.to_list($$Array.mapi((function (i, param) { let str_result = param[2]; let f = param[1]; let fmt = param[0]; @@ -450,9 +450,7 @@ let extra = Pervasives.$at(suites, Pervasives.$at($$Array.to_list($$Array.mapi(( }; }) ]; -}), of_string_data))))); - -Mt.from_pair_suites("Caml_format_test", extra); +}), of_string_data)))))); let float_suites = { hd: "float_nan", diff --git a/jscomp/test/digest_test.js b/jscomp/test/digest_test.js index 645a59a61f..f6f053b4cc 100644 --- a/jscomp/test/digest_test.js +++ b/jscomp/test/digest_test.js @@ -145,7 +145,7 @@ let ref = [ "b325dc1c6f5e7a2b7cf465b9feab7948" ]; -let extra = Pervasives.$at({ +Mt.from_pair_suites("Digest_test", Pervasives.$at({ hd: [ "File \"digest_test.res\", line 9, characters 9-16", (function () { @@ -228,9 +228,7 @@ let extra = Pervasives.$at({ }; }) ]; -}), Ext_array_test.range(0, 129)))); - -Mt.from_pair_suites("Digest_test", extra); +}), Ext_array_test.range(0, 129))))); exports.f = f; -/* extra Not a pure module */ +/* Not a pure module */ diff --git a/jscomp/test/float_test.js b/jscomp/test/float_test.js index 9968b2483c..7998fe9d09 100644 --- a/jscomp/test/float_test.js +++ b/jscomp/test/float_test.js @@ -322,7 +322,7 @@ let b = match$4[1]; let a = match$4[0]; -let extra = Pervasives.$at({ +Mt.from_pair_suites("Float_test", Pervasives.$at({ hd: [ "mod_float", (function () { @@ -370,9 +370,7 @@ let extra = Pervasives.$at({ } } } -}, Pervasives.$at(from_pairs(results), suites.contents)); - -Mt.from_pair_suites("Float_test", extra); +}, Pervasives.$at(from_pairs(results), suites.contents))); exports.test_id = test_id; exports.suites = suites; diff --git a/jscomp/test/int64_mul_div_test.js b/jscomp/test/int64_mul_div_test.js index 6935d118e7..0b3755be19 100644 --- a/jscomp/test/int64_mul_div_test.js +++ b/jscomp/test/int64_mul_div_test.js @@ -1600,7 +1600,7 @@ function from_to_string(xs) { }), $$Array.to_list(xs)); } -let extra = Pervasives.$at(from_pairs("random", pairs), Pervasives.$at(from_pairs("small", small_pairs), Pervasives.$at(List.mapi((function (i, param) { +Mt.from_pair_suites("Int64_mul_div_test", Pervasives.$at(from_pairs("random", pairs), Pervasives.$at(from_pairs("small", small_pairs), Pervasives.$at(List.mapi((function (i, param) { let f = param[1]; let i64 = param[0]; return [ @@ -1676,9 +1676,7 @@ let extra = Pervasives.$at(from_pairs("random", pairs), Pervasives.$at(from_pair tl: /* [] */0 } } -}))))))); - -Mt.from_pair_suites("Int64_mul_div_test", extra); +})))))))); exports.commutative_mul = commutative_mul; exports.pairs = pairs; @@ -1693,4 +1691,4 @@ exports.to_string = to_string; exports.int64_compare_tests = int64_compare_tests; exports.from_compare = from_compare; exports.from_to_string = from_to_string; -/* extra Not a pure module */ +/* Not a pure module */ diff --git a/jscomp/test/map_find_test.js b/jscomp/test/map_find_test.js index 10193d80f0..31ef48ae2c 100644 --- a/jscomp/test/map_find_test.js +++ b/jscomp/test/map_find_test.js @@ -367,36 +367,30 @@ let s = List.fold_left((function (acc, param) { } }); -let extra_0 = [ - "int", - (function () { - return { - TAG: "Eq", - _0: find(10, m), - _1: /* 'a' */97 - }; - }) -]; - -let extra_1 = { +Mt.from_pair_suites("Map_find_test", { hd: [ - "string", + "int", (function () { return { TAG: "Eq", - _0: find$1("10", s), + _0: find(10, m), _1: /* 'a' */97 }; }) ], - tl: /* [] */0 -}; - -let extra = { - hd: extra_0, - tl: extra_1 -}; - -Mt.from_pair_suites("Map_find_test", extra); + tl: { + hd: [ + "string", + (function () { + return { + TAG: "Eq", + _0: find$1("10", s), + _1: /* 'a' */97 + }; + }) + ], + tl: /* [] */0 + } +}); /* m Not a pure module */ diff --git a/jscomp/test/string_test.js b/jscomp/test/string_test.js index f68a72d7b0..23f7e57812 100644 --- a/jscomp/test/string_test.js +++ b/jscomp/test/string_test.js @@ -127,10 +127,10 @@ function xsplit(delim, s) { } function string_of_chars(x) { - let extra = List.map((function (prim) { + let xs = List.map((function (prim) { return String.fromCharCode(prim); }), x); - return $$Array.of_list(extra).join(""); + return $$Array.of_list(xs).join(""); } Mt.from_pair_suites("String_test", { diff --git a/jscomp/test/test_demo.js b/jscomp/test/test_demo.js index 75af4c0fc1..4dc6253a4e 100644 --- a/jscomp/test/test_demo.js +++ b/jscomp/test/test_demo.js @@ -62,8 +62,7 @@ let x = Curry._1(g(3, 5), 6); function v(extra) { let u = 7; - let xx = 6; - return (xx + extra | 0) + u | 0; + return (6 + extra | 0) + u | 0; } let nil = "Nil"; diff --git a/jscomp/test/test_google_closure.js b/jscomp/test/test_google_closure.js index 5ca02ed7de..d399ff9dce 100644 --- a/jscomp/test/test_google_closure.js +++ b/jscomp/test/test_google_closure.js @@ -28,7 +28,9 @@ let arr = $$Array.init(2, (function (param) { })); for(let i = 0; i <= 1; ++i){ - let f3$1 = f2(i); + let f3$1 = function (extra) { + return i + 1 | 0; + }; Caml_array.set(arr, i, Curry._1(f3$1, 2)); } diff --git a/lib/es6/js.js b/lib/es6/js.js index f973eb67db..33d3fc0ab1 100644 --- a/lib/es6/js.js +++ b/lib/es6/js.js @@ -1,8 +1,6 @@ -let Internal = {}; - let Null; let Undefined; @@ -74,7 +72,6 @@ let $$Map; let $$WeakMap; export { - Internal, Null, Undefined, Nullable, diff --git a/lib/js/js.js b/lib/js/js.js index b82645f58d..234cb1818c 100644 --- a/lib/js/js.js +++ b/lib/js/js.js @@ -1,8 +1,6 @@ 'use strict'; -let Internal = {}; - let Null; let Undefined; @@ -73,7 +71,6 @@ let $$Map; let $$WeakMap; -exports.Internal = Internal; exports.Null = Null; exports.Undefined = Undefined; exports.Nullable = Nullable;