Skip to content

Commit 460194c

Browse files
committed
2nd round clean up
- check Js_oo.unsafe_downgrade later
1 parent deff89f commit 460194c

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

70 files changed

+321
-330
lines changed

jscomp/main/builtin_cmi_datasets.ml

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

jscomp/others/js_OO.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424

2525
[@@@bs.config {flags = [|"-unboxed-types"|]}]
2626
(**/**)
27-
external unsafe_downgrade : 'a Js.t -> 'a = "#unsafe_downgrade"
27+
external unsafe_downgrade : 'a -> 'a = "#unsafe_downgrade"
2828
external unsafe_to_method : 'a -> 'a = "#fn_method"
2929
(**/**)
3030
module Callback = struct

jscomp/others/js_obj.ml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
*)
2727

2828
(** [empty ()] returns the empty object [\{\}] *)
29-
external empty : unit -> < .. > Js.t = "" [@@bs.obj]
29+
external empty : unit -> < .. > = "" [@@bs.obj]
3030

3131
(** [assign target source] copies properties from [source] to [target]
3232
@@ -63,7 +63,7 @@ let _ = Js.log target
6363
6464
@see <https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/assign> MDN
6565
*)
66-
external assign : < .. > Js.t -> < .. > Js.t -> < .. > Js.t = "Object.assign" [@@bs.val]
66+
external assign : < .. > -> < .. > -> < .. > = "Object.assign" [@@bs.val]
6767

6868
(* TODO:
6969
@@ -103,4 +103,4 @@ Put directly on Js?
103103
104104
@see <https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/keys> MDN
105105
*)
106-
external keys : _ Js.t -> string array = "Object.keys" [@@bs.val]
106+
external keys : < .. > -> string array = "Object.keys" [@@bs.val]

jscomp/others/node.ml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ type node_module = <
5050
loaded : bool;
5151
children : node_module array ;
5252
paths : string array;
53-
> Js.t
53+
>
5454
(* WARN:
5555
its path name should not be changed
5656
see {!Ppx_entry}
@@ -61,7 +61,7 @@ type node_require = <
6161

6262
resolve : string -> string [@bs]
6363
(* @raise exception *)
64-
> Js.t
64+
>
6565
(* WARN:
6666
its path name should not be changed
6767
see {!Ppx_entry}

jscomp/others/node_child_process.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,5 +45,5 @@ external readAs : spawnResult ->
4545
status : int Js.null;
4646
signal : string Js.null ;
4747
stdout : Node.string_buffer Js.null ;
48-
stderr : Node.string_buffer Js.null > Js.t =
48+
stderr : Node.string_buffer Js.null > =
4949
"%identity"

jscomp/others/node_module.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,5 +25,5 @@
2525
(** Node Module API *)
2626

2727
external module_ :
28-
< __cache : Node.node_module Js_dict.t > Js.t
28+
< __cache : Node.node_module Js_dict.t >
2929
= "module" [@@bs.val]

jscomp/others/node_path.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ type pathObject =
4141
base : string ;
4242
name : string ;
4343
ext : string
44-
> Js.t
44+
>
4545

4646
external format : pathObject -> string = "format" [@@bs.module "path"]
4747

jscomp/others/node_process.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ type t =
3333
disconnect : unit -> unit [@bs.meth];
3434
platform : string;
3535
env : string Js_dict.t; (* ocamldep sucks which can not map [Js.Dic.t] to [Js_dict.t]*)
36-
> Js.t
36+
>
3737

3838
external process : t = "process" [@@bs.module]
3939
external argv : string array = "argv" [@@bs.module "process"]

jscomp/others/node_process.mli

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ type t =
3232
disconnect : unit -> unit [@bs.meth];
3333
platform : string;
3434
env : string Js_dict.t; (* ocamldep sucks which can not map [Js.Dic.t] to [Js_dict.t]*)
35-
> Js.t
35+
>
3636
(* FIXME : use record *)
3737

3838
external process : t = "process" [@@bs.module]

jscomp/test/arity_ml.ml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ or [@@unboxed]. *)
3030
3131
;; h (object [@bs] method hi x y =x + y end )
3232
33-
Error: This expression has type < hi : (int -> int -> int [@bs.meth]) > Js.t
33+
Error: This expression has type < hi : (int -> int -> int [@bs.meth]) >
3434
but an expression was expected of type
35-
< hi : (int -> int -> 'a [@bs]); .. > Js.t
35+
< hi : (int -> int -> 'a [@bs]); .. >
3636
Types for method hi are incompatible *)

0 commit comments

Comments
 (0)