Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Type error on record declarations too hard to read #4819

Closed
vicuna opened this issue Jun 9, 2009 · 1 comment
Closed

Type error on record declarations too hard to read #4819

vicuna opened this issue Jun 9, 2009 · 1 comment
Assignees

Comments

@vicuna
Copy link

vicuna commented Jun 9, 2009

Original bug ID: 4819
Reporter: till
Assigned to: @garrigue
Status: closed (set by @garrigue on 2010-05-21T03:51:47Z)
Resolution: fixed
Priority: normal
Severity: feature
Fixed in version: 3.12.0+dev
Category: ~DO NOT USE (was: OCaml general)
Related to: #4478
Monitored by: @ygrek jm

Bug description

When dealing with long record definitions error messages such as:
sig type t = { a : int; b : int; c : int; d : int; } end
is not included in
sig type t = { a : int; b : int; c : int; } end
become hard to read because divergences are not pointed out explicitly

Module signature handle this in a nice way:
Modules do not match:
sig val a : int val b : int val c : int end
is not included in
sig val a : int val b : int val c : int val d : int end
The field `d' is required but not provided

it would be great to have this for records too.

Additional information

Other types such as variants and objects could probably benefit from such an improved error reporting.

@vicuna
Copy link
Author

vicuna commented May 21, 2010

Comment author: @garrigue

Fixed together with #4478.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants