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

Go: Avoid using getTarget() as it may not exist #13785

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

owen-mc
Copy link
Contributor

@owen-mc owen-mc commented Jul 20, 2023

Try to also deal with the case that we are calling a function through a variable that it has been assigned to.

Try to also deal with the case that we are calling a function
through a variable that it has been assigned to.
@owen-mc owen-mc changed the title Avoid using getTarget() as it may not exist Go: Avoid using getTarget() as it may not exist Jul 20, 2023
@github-actions github-actions bot added the Go label Jul 20, 2023
@smowton
Copy link
Contributor

smowton commented Jul 27, 2023

Worth noting that this changes behaviour somewhat: now if the receiver is of non-interface type but the callee is promoted from an embedded interface, we'll call this a non-interface call and propagate the receiver into it. Contrast the old test which I think looked at getACalleeSource instead of getTarget, and would have maintained the same behaviour regarding that scenario.

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

Successfully merging this pull request may close these issues.

None yet

2 participants