Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0006381OCamlOCaml generalpublic2014-04-26 00:062014-09-15 09:50
Reporterdbuenzli 
Assigned To 
PrioritynormalSeverityminorReproducibilityhave not tried
StatusfeedbackResolutionopen 
PlatformOSOS Version
Product Version4.01.0 
Target Version4.02.2+devFixed in Version 
Summary0006381: Report unbound variables before other errors
DescriptionWould it be possible to always report unbound variable error before other errors ? Sometimes with optional arguments we get misleading errors. Here is an example:

# let f ?(opt = 2) x y = x + y;;
# f 2 zorglub 3;;
Error: The function applied to this argument has type ?opt:int -> int
This argument cannot be applied without label

Thanks.
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0011598)
shinwell (developer)
2014-05-30 14:29

Does anyone else have any opinions on the proposal?
(0011860)
doligez (administrator)
2014-07-16 17:50

Is it worth making the typechecker even more complex? I don't find the example particularly convincing.

- Issue History
Date Modified Username Field Change
2014-04-26 00:06 dbuenzli New Issue
2014-05-30 14:29 shinwell Note Added: 0011598
2014-05-30 14:29 shinwell Status new => feedback
2014-07-16 17:50 doligez Note Added: 0011860
2014-07-16 17:50 doligez Target Version => 4.02.1+dev
2014-09-04 00:25 doligez Target Version 4.02.1+dev => undecided
2014-09-15 09:50 doligez Target Version undecided => 4.02.2+dev


Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker