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

Using same function name more than once is possible #3395

Open
tw2021 opened this issue Sep 3, 2021 · 1 comment
Open

Using same function name more than once is possible #3395

tw2021 opened this issue Sep 3, 2021 · 1 comment
Labels
Feature: Functions Function signature, creation, management

Comments

@tw2021
Copy link

tw2021 commented Sep 3, 2021

Describe the bug
It's possible to rename 2 or more functions, all having the same name. This can cause confusion if it was not desired / an accident.

To Reproduce
Steps to reproduce the behavior:

Rename a function, for example to "function1".
Rename another function within the same scope to the same name "function1".
This works: The user now has 2 different functions with the same name.
This is highly confusing.
It's like having 2 children and giving them both the same name.
It's not forbidden, but makes everything extremely complicated.

Expected behavior
There should at least be a warning to the user that the same name is already in use.

Screenshots
Animation

Environment (please complete the following information):

  • Ghidra Version: 10.0.2
  • Ghidra Origin: official ghidra-sre.org distro
@mumbel
Copy link
Contributor

mumbel commented Sep 4, 2021

This is expected behavior, manage your naming better if it's confusing, or use namespaces. I have 3 implementations of memcpy in my binary, I should name them differently than what they are because how they were linked in? No

@ryanmkurtz ryanmkurtz added the Feature: Functions Function signature, creation, management label Sep 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature: Functions Function signature, creation, management
Projects
None yet
Development

No branches or pull requests

3 participants