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

Annotation for function name #17204

Merged

Conversation

NirmalManoj
Copy link
Contributor

@NirmalManoj NirmalManoj commented Jul 3, 2020

Your checklist for this pull request

  • I've read the guidelines for contributing to this repository
  • I made sure to follow the project's coding style
  • I've added tests that prove my fix is effective or that my feature works (if possible)
  • I've updated the documentation and the radare2 book with the relevant information (if needed)

Detailed description

This PR adds an annotation type (R_CODE_ANNOTATION_TYPE_FUNCTION_NAME) for function names in the decompiled code. This will be required for implementing some features in the decompiler in Cutter.

Note: I haven't modified tests so CI can fail during tests due to this. I will modify tests after getting feedback on this.

...

Test plan

  1. Fetch and compile PR #123 from r2ghidra-dec after compiling this PR.
  • Check the code and make sure that I haven't missed anything.
  • Check the modified JSON output code to make sure it's correct.
  • Test the code with JSON output to see if it's working properly.

...

Closing issues

...

@NirmalManoj NirmalManoj marked this pull request as ready for review Jul 3, 2020
@NirmalManoj NirmalManoj requested a review from trufae as a code owner Jul 3, 2020
@NirmalManoj NirmalManoj requested review from thestr4ng3r and karliss Jul 3, 2020
@NirmalManoj NirmalManoj self-assigned this Jul 3, 2020
@karliss
Copy link
Contributor

karliss commented Jul 3, 2020

I would recommend keeping changes in separate branch just like it is currently done with matching cutter changes.

@NirmalManoj
Copy link
Contributor Author

NirmalManoj commented Jul 3, 2020

@karliss Sure, I will make a branch with the same name decompiler-refactoring.

@github-actions github-actions bot added the API New API requests, changes, removal label Jul 3, 2020
@XVilka XVilka requested a review from ret2libc Jul 6, 2020
@NirmalManoj NirmalManoj requested a review from karliss Jul 8, 2020
@NirmalManoj NirmalManoj changed the base branch from master to decompiler-refactoring Jul 9, 2020
karliss
karliss approved these changes Jul 9, 2020
@XVilka XVilka merged commit e284065 into radareorg:decompiler-refactoring Jul 10, 2020
6 checks passed
@XVilka
Copy link
Contributor

XVilka commented Jul 10, 2020

@NirmalManoj @karliss @thestr4ng3r do we need to merge it in master? Or it's preliminary yet?

@NirmalManoj
Copy link
Contributor Author

NirmalManoj commented Jul 10, 2020

@XVilka I haven't made unit tests for function name annotation yet, and I think it will be better if that's done later after all new types of annotations are added. Also, this PR won't improve Cutter or r2ghidra-dec right now as the corresponding improvements are in decompiler-refactoring branches.

@NirmalManoj NirmalManoj moved this from In progress to Done in Improving Decompiler Widget (GSoC) Jul 15, 2020
NirmalManoj added a commit that referenced this pull request Jul 17, 2020
NirmalManoj added a commit that referenced this pull request Jul 26, 2020
NirmalManoj added a commit to NirmalManoj/radare2 that referenced this pull request Jul 28, 2020
NirmalManoj added a commit to NirmalManoj/radare2 that referenced this pull request Jul 28, 2020
NirmalManoj added a commit to NirmalManoj/radare2 that referenced this pull request Jul 28, 2020
NirmalManoj added a commit to NirmalManoj/radare2 that referenced this pull request Jul 28, 2020
NirmalManoj added a commit to NirmalManoj/radare2 that referenced this pull request Jul 28, 2020
NirmalManoj added a commit to NirmalManoj/radare2 that referenced this pull request Aug 6, 2020
NirmalManoj added a commit that referenced this pull request Aug 9, 2020
ITAYC0HEN pushed a commit that referenced this pull request Aug 10, 2020
…edCode (#17429)

* Annotation for function name (#17204)
* Annotations for Constant Variables and Global Variables for the decompiler (#17281)
* Annotation For Function Variables (#17375)
* function variable annotation added (includes local variable and function parameter)
* API for checking if an annotation is a reference or function variable. (#17386)
* Update docs in annotate code API  (#17397)
* Unit tests for annotated code API (#17403)
ret2libc pushed a commit to ret2libc/radare2 that referenced this pull request Sep 1, 2020
…edCode (radareorg#17429)

* Annotation for function name (radareorg#17204)
* Annotations for Constant Variables and Global Variables for the decompiler (radareorg#17281)
* Annotation For Function Variables (radareorg#17375)
* function variable annotation added (includes local variable and function parameter)
* API for checking if an annotation is a reference or function variable. (radareorg#17386)
* Update docs in annotate code API  (radareorg#17397)
* Unit tests for annotated code API (radareorg#17403)
ret2libc pushed a commit that referenced this pull request Sep 2, 2020
…edCode (#17429)

* Annotation for function name (#17204)
* Annotations for Constant Variables and Global Variables for the decompiler (#17281)
* Annotation For Function Variables (#17375)
* function variable annotation added (includes local variable and function parameter)
* API for checking if an annotation is a reference or function variable. (#17386)
* Update docs in annotate code API  (#17397)
* Unit tests for annotated code API (#17403)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API New API requests, changes, removal
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

None yet

4 participants