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: 4904 Reporter: lukstafi Assigned to:@alainfrisch Status: closed (set by @alainfrisch on 2017-02-20T09:56:36Z) Resolution: won't fix Priority: normal Severity: feature Category: ~DO NOT USE (was: OCaml general) Has duplicate:#7029 Monitored by: domsj @gasche@ygrek@hcarty
Bug description
If this feature is implemented, the warning should be on by default.
let f ?(a=0) b ?(a=0) c = a+b+c;;
val f : ?a:int -> int -> ?a:int -> int -> int =
f ~a:7 1 2;;
: int = 3
The text was updated successfully, but these errors were encountered:
This case is covered by warning 27, which is not enabled by default.
Should we move it to warning 26 (which is enabled by default)?
What could be a good criterion? A combination of unused variable and shadowing?
I move it to Alain, since he is our unused variable specialist...
As the original reporter, I would not object for this bug to be closed; perhaps as "Won't fix" -- referring to making this case enabled -- if the unused variable detection "warning 27" is covering this case since time immemorial. If this case (with labeled arguments) can be easily/efficiently differentiated though, it would still be beneficial to move it to warning 26 I think.
I confirm that warning 27 is triggered (not in the toplevel, though). I don't think that triggering warning 26 for this case is relevant considering the current description of warning 26 (unused variable that is bound with "let" or "as"). And it would be weird to have a different warning than for
Original bug ID: 4904
Reporter: lukstafi
Assigned to: @alainfrisch
Status: closed (set by @alainfrisch on 2017-02-20T09:56:36Z)
Resolution: won't fix
Priority: normal
Severity: feature
Category: ~DO NOT USE (was: OCaml general)
Has duplicate: #7029
Monitored by: domsj @gasche @ygrek @hcarty
Bug description
If this feature is implemented, the warning should be on by default.
let f ?(a=0) b ?(a=0) c = a+b+c;;
val f : ?a:int -> int -> ?a:int -> int -> int =
f ~a:7 1 2;;
The text was updated successfully, but these errors were encountered: