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: 4838 Reporter:@yallop Assigned to:@garrigue Status: closed (set by @garrigue on 2012-06-01T07:24:03Z) Resolution: fixed Priority: normal Severity: feature Version: 3.11.1 Fixed in version: 4.00.0+dev Category: ~DO NOT USE (was: OCaml general) Related to:#4511 Monitored by: till "Julien Signoles" @yallop@hcarty
Bug description
Expressions of the form
let module M = in e
are currently always treated as expansive by the type checker. As a result, in the following declaration "id" is given a non-polymorphic type:
let id = let module M = struct end in fun x -> x
(There are, of course, useful examples as well, particularly where the module expression declares types.)
It seems that many such expressions (including all those where the module-expr is built from non-expansive terms) could be safely treated as non-expansive, increasing the number of typeable programs.
Original bug ID: 4838
Reporter: @yallop
Assigned to: @garrigue
Status: closed (set by @garrigue on 2012-06-01T07:24:03Z)
Resolution: fixed
Priority: normal
Severity: feature
Version: 3.11.1
Fixed in version: 4.00.0+dev
Category: ~DO NOT USE (was: OCaml general)
Related to: #4511
Monitored by: till "Julien Signoles" @yallop @hcarty
Bug description
Expressions of the form
let module M = in e
are currently always treated as expansive by the type checker. As a result, in the following declaration "id" is given a non-polymorphic type:
let id = let module M = struct end in fun x -> x
(There are, of course, useful examples as well, particularly where the module expression declares types.)
It seems that many such expressions (including all those where the module-expr is built from non-expansive terms) could be safely treated as non-expansive, increasing the number of typeable programs.
Additional information
Patch against 3.11.1 attached.
File attachments
The text was updated successfully, but these errors were encountered: