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

[gosrc2cpg] - Handling for package level global variable access. Fixes #3695 #3703

Merged
merged 3 commits into from
Oct 2, 2023

Conversation

pandurangpatil
Copy link
Contributor

Handling for package level global variable access. Fixes #3695

  1. Handled package level global variable access with FieldAccess CALL node with respective handling to set the TypeFullName properly.
  2. Made changes to handle the situation where we couldn't identify the TypeFullName in that situation, we are setting the TypeFullName of the receiver with respective labels postfixed to it like <FieldAccess> or <ReturnType>.
  3. Updated respective unit tests along with a few more unit tests.

TODO:
Need to handle Global Variable Declaration.

1. Handled package level global variable access with FieldAccess `CALL`
node with respective handling to set the TypeFullName properly.
2. Made changes to handle the situation where we couldn't identify the
TypeFullName in that situation, we are setting the TypeFullName of the
receiver with respective labels postfixed to it like `<FieldAccess>` or
`<ReturnType>`.
3. Updated respective unit tests along with a few more unit tests.

TODO:
Need to handle Global Variable Declaration.
@DavidBakerEffendi DavidBakerEffendi merged commit dd00f32 into joernio:master Oct 2, 2023
@pandurangpatil pandurangpatil deleted the issue-3695 branch October 2, 2023 08:16
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.

[GO] Handle global variable and constant
2 participants