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

Improve error reporting #5

Open
smimram opened this issue Jun 14, 2018 · 1 comment
Open

Improve error reporting #5

smimram opened this issue Jun 14, 2018 · 1 comment

Comments

@smimram
Copy link
Collaborator

smimram commented Jun 14, 2018

Please improve error reporting. For instance,

coh comp (x : *) (y : *) (f : x -> y) (z : *) (g : y -> z) : x -> z.

let test (x : *) (y : *) (f : x -> y) = comp f f.

results in

=^.^= let comp = x -> z
=I.I= defined.

Fatal error: exception Common.NotEqual("x", "y")

I would expect the line and character number of the error and the fact that the second f is expected to be of type y -> ... but is of type x -> y.

@smimram
Copy link
Collaborator Author

smimram commented Jun 14, 2018

Another one:

coh comp (x : *) (y : *) (f : x -> y) (z : *) (g : y -> z) : x -> z.

coh test (x : *) (x : *) (f : x -> y) : comp f f -> f.

gives

=^.^= let comp = x -> z
=I.I= defined.

=^.^= let test = (comp f f) -> f
Fatal error: exception Common.DoubleDef("x")

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