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

Call analysis improvements #165

Merged

Conversation

ds5678
Copy link
Contributor

@ds5678 ds5678 commented Dec 7, 2022

No description provided.

@ds5678 ds5678 marked this pull request as draft December 8, 2022 04:40
@ds5678 ds5678 marked this pull request as ready for review December 8, 2022 06:50
@ds5678
Copy link
Contributor Author

ds5678 commented Dec 8, 2022

I made a few more improvements to improve the output:

  • All primitive types are correctly resolved now.
  • Concrete generics are handled properly so that they no longer show up as unknown methods.
  • Lists of concrete generics are consolidated into their common base type.
  • PE exports no longer get counted as unknown calls.

Possible improvements for the future:

  • The Type field of CallsAttribute and CalledByAttribute sometimes attempts to reference an inaccessible type such as System.ThrowHelper or a type from an unreferenced module. Adding a string TypeName field might be desirable to handle these edge cases.
  • The Member field of CallsAttribute and CalledByAttribute currently just contains the member's name. A full signature might be better for removing ambiguity.
  • Generic types in the Type field currently don't have type parameters. It may be desirable to retain that information and use it to fill those parameters where feasible.

@ds5678
Copy link
Contributor Author

ds5678 commented Dec 13, 2022

I implemented a system for verifying that a type is accessible. In the event it isn't, TypeFullName is used instead. I do not plan on implementing any of the other potential improvements in this pull request.

@ds5678 ds5678 force-pushed the call-analysis-improvements branch from e3475c0 to fc621c4 Compare December 14, 2022 00:00
@SamboyCoding SamboyCoding merged commit b1a509e into SamboyCoding:development Dec 17, 2022
@ds5678 ds5678 deleted the call-analysis-improvements branch December 17, 2022 22:30
CyberiaResurrection pushed a commit to Algo-Web/Cpp2IL that referenced this pull request Apr 14, 2023
CyberiaResurrection pushed a commit to Algo-Web/Cpp2IL that referenced this pull request Apr 14, 2023
CyberiaResurrection pushed a commit to Algo-Web/Cpp2IL that referenced this pull request Apr 14, 2023
CyberiaResurrection pushed a commit to Algo-Web/Cpp2IL that referenced this pull request Apr 14, 2023
CyberiaResurrection pushed a commit to Algo-Web/Cpp2IL that referenced this pull request Apr 14, 2023
CyberiaResurrection pushed a commit to Algo-Web/Cpp2IL that referenced this pull request Apr 14, 2023
CyberiaResurrection pushed a commit to Algo-Web/Cpp2IL that referenced this pull request Apr 14, 2023
CyberiaResurrection pushed a commit to Algo-Web/Cpp2IL that referenced this pull request Apr 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants