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: 4884 Reporter: laurent Status: closed (set by @garrigue on 2010-04-30T03:08:56Z) Resolution: fixed Priority: normal Severity: minor Version: 3.11.1 Fixed in version: 3.12.0+dev Category: ~DO NOT USE (was: OCaml general) Has duplicate:#5075 Related to:#4937 Monitored by:@ygrek
Bug description
The following code fails:
module M = struct
type t = Some of int
let f ?(v2=0) v1 = v1 + v2
end
The problem is probably that optional arguments are soon translated in some other code that uses the Some constructor without specifying the module (Pervasives.Some).
I agree that defining a new Some constructor is probably a bad practice but if OCaml relies on Some not being redefined, then redefining Some should produce an error.
The text was updated successfully, but these errors were encountered:
Original bug ID: 4884
Reporter: laurent
Status: closed (set by @garrigue on 2010-04-30T03:08:56Z)
Resolution: fixed
Priority: normal
Severity: minor
Version: 3.11.1
Fixed in version: 3.12.0+dev
Category: ~DO NOT USE (was: OCaml general)
Has duplicate: #5075
Related to: #4937
Monitored by: @ygrek
Bug description
The following code fails:
module M = struct
type t = Some of int
let f ?(v2=0) v1 = v1 + v2
end
The problem is probably that optional arguments are soon translated in some other code that uses the Some constructor without specifying the module (Pervasives.Some).
I agree that defining a new Some constructor is probably a bad practice but if OCaml relies on Some not being redefined, then redefining Some should produce an error.
The text was updated successfully, but these errors were encountered: