-
Notifications
You must be signed in to change notification settings - Fork 13
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
Flycheck seems to report success when error is in included file #8
Comments
Thanks. Just to clarify, this is distinct from #5, right? I think the bug is probably in the Dafny server. |
Actually, scratch that, at least in part. The error is properly reported, but it's discarded by Flycheck, because Flycheck discards errors in included files. flycheck/flycheck#972 was going to fix this, but the contributor didn't complete the implementation :/ There's an easy fix that can be implemented on the Dafny side. In addition to reporting the original error in Then that error would appear when verifying B.dfy. |
That's frustrating.
Sounds good to me! I've filed dafny-lang/dafny#16 documenting this proposed solution. |
Indeed :) If you're curious about ELisp, this could be a nice starting project! |
This is fixed now |
Suppose I create two files,
A.dfy
andB.dfy
, as follows:A.dfy
:B.dfy
:When viewing
A.dfy
, the type error in the body ofProblem
is correctly identified. However, when viewingB.dfy
, no error is reported (the Flycheck status in the modeline indicates no errors, and there are no errors to be jumped to via Flycheck keybindings). Commenting theinclude
statement causes the unprovable lemma to be correctly identified.In general, this problem is: when there is a syntax or type error in an included file (i.e.
A.dfy
), verification of the including module (i.e.B.dfy
) appears to succeed. A verification error in the included file will not cause this effect, and this effect will not mask the reporting of syntax or type errors in the including file—only verification errors are masked by this problem.It's unclear to me whether the fix to this bug lies with Dafny or with the Emacs mode; paging @RustanLeino for further discussion of this.
The text was updated successfully, but these errors were encountered: