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

Print innermost backtrace mark for uncaught exception even with backtrace printing off #1619

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

sim642
Copy link
Member

@sim642 sim642 commented Nov 4, 2024

Closes #1616.

The output for the problematic example is now

Fatal error: exception LibraryDsl.Pattern.Expected("^::")
Marked with function pthread_create

It's still not the best output like #1616 (comment). That's the intended output for such problem with the clearest error message, but if the problematic call is the only one in the program, then CIL doesn't seem to be doing some unification with the declaration that it otherwise would.

@michael-schwarz
Copy link
Member

michael-schwarz commented Nov 4, 2024

Should the error message not also contain some human-readable information such as
Check that the input program compiles with GCC. If it does, the specification of the library function in Goblint is likely incorrect or incomplete. When appropriate, you could also try commenting out the offending call.?

The current error message is only helpful to Goblint developers (who are familiar with the library mechanism); such an error message would also give other users a way to bypass this message or understand what's happening.

@sim642
Copy link
Member Author

sim642 commented Nov 12, 2024

Should the error message not also contain some human-readable information such as
Check that the input program compiles with GCC. If it does, the specification of the library function in Goblint is likely incorrect or incomplete. When appropriate, you could also try commenting out the offending call.?

I'm not sure we should make exception strings such spoon-feedy text. If we want to be consistent about it, we should change every CIL lexing/parsing/typing/merging/etc error to also to print it. #1564 clearly shows it.
Or should we suggest the user delete their code to avoid Goblint erroring on it?

such an error message would also give other users a way to bypass this message

Not really. The only they have to be Goblint developers to actually fix LibraryFunctions.

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

Successfully merging this pull request may close these issues.

Error message from library mechanism are unhelpful to users
2 participants