You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Original bug ID: 6209 Reporter: jpdeplaix Assigned to:@gasche Status: closed (set by @gasche on 2013-10-19T10:09:50Z) Resolution: duplicate Priority: normal Severity: minor Version: 4.01.0 Category: typing Duplicate of:#5460
Bug description
I'm unable to override module types inside module with the := method which works for types and modules but not module types.
The following examples will be more explicits.
Is there a
Steps to reproduce
module A = struct
module B = struct
let test = 1
end
end;;
(* module A : sig module B : sig val test : int end end *)
module C = struct
include (A : module type of A with module B := A.B)
module B = struct
let test = "1"
end
end;;
(* module C : sig module B : sig val test : string end end *)
module D = struct
type e = int
end;;
(* module D : sig type e = int end *)
module F = struct
include (D : module type of D with type e := D.e)
type e = string
end;;
(* module F : sig type e = string end *)
module G = struct
module type H = sig
val test : int
end
end;;
(* module G : sig module type H = sig val test : int end end *)
module I = struct
include (G : module type of G with module type H := G.H)
module type H = sig
val test : string
end
end;;
(* Syntax error: ')' expected, the highlighted '(' might be unmatched *)
Additional information
Tested with 4.01.0 and with the latest trunk (349f151)
The text was updated successfully, but these errors were encountered:
Original bug ID: 6209
Reporter: jpdeplaix
Assigned to: @gasche
Status: closed (set by @gasche on 2013-10-19T10:09:50Z)
Resolution: duplicate
Priority: normal
Severity: minor
Version: 4.01.0
Category: typing
Duplicate of: #5460
Bug description
I'm unable to override module types inside module with the := method which works for types and modules but not module types.
The following examples will be more explicits.
Is there a
Steps to reproduce
module A = struct
module B = struct
let test = 1
end
end;;
(* module A : sig module B : sig val test : int end end *)
module C = struct
include (A : module type of A with module B := A.B)
module B = struct
let test = "1"
end
end;;
(* module C : sig module B : sig val test : string end end *)
module D = struct
type e = int
end;;
(* module D : sig type e = int end *)
module F = struct
include (D : module type of D with type e := D.e)
type e = string
end;;
(* module F : sig type e = string end *)
module G = struct
module type H = sig
val test : int
end
end;;
(* module G : sig module type H = sig val test : int end end *)
module I = struct
include (G : module type of G with module type H := G.H)
module type H = sig
val test : string
end
end;;
(* Syntax error: ')' expected, the highlighted '(' might be unmatched *)
Additional information
Tested with 4.01.0 and with the latest trunk (349f151)
The text was updated successfully, but these errors were encountered: