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

Add a comment section containing error message to error tests #280

Closed
operasfantom opened this issue Jun 14, 2022 · 2 comments · Fixed by #583
Closed

Add a comment section containing error message to error tests #280

operasfantom opened this issue Jun 14, 2022 · 2 comments · Fixed by #583
Assignees
Labels
enhancement New feature or request good first issue Good for newcomers verified Bug fix is verified

Comments

@operasfantom
Copy link
Collaborator

operasfantom commented Jun 14, 2022

KLEE prints .err files containing error message, file location, line number, and more. For example:

Error: memory error: invalid pointer: free
File: /tmp/code/code.c
Line: 8
assembly.ll line: 23
Stack: 
	#000000023 in main (=1, =36263824) at /tmp/code/code.c:8
Info: 
	address: 36291136
	next: object at 36963008 of size 23
		MO19[23] allocated at main():  %3 = alloca i32, align 4
	prev: object at 36291112 of size 8
		MO33[8] allocated at main():  %6 = alloca i8*, align 8

This information may be used in order to produce comments above the error test or its function call, similar to UTBotJava's approach.

@operasfantom operasfantom added the enhancement New feature or request label Jun 14, 2022
@korifey korifey moved this to Todo in UTBot C/C++ Jun 14, 2022
@operasfantom operasfantom added the good first issue Good for newcomers label Jun 16, 2022
@alexey-utkin
Copy link
Collaborator

While the fix, please, take a look at SARIF report creation procedure. Seems the most of code can be extended a bit and be reused.

@Nypiaka Nypiaka linked a pull request Feb 8, 2023 that will close this issue
@github-project-automation github-project-automation bot moved this from Todo to Done in UTBot C/C++ Feb 14, 2023
@tyuldashev tyuldashev added the verified Bug fix is verified label Feb 14, 2023
@operasfantom
Copy link
Collaborator Author

Well done!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers verified Bug fix is verified
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

5 participants