-
Notifications
You must be signed in to change notification settings - Fork 2.5k
bug(forge): Function signature collisions can cause panics #612
Copy link
Copy link
Closed
Labels
C-forgeCommand: forgeCommand: forgeCmd-forge-testCommand: forge testCommand: forge testP-normalPriority: normalPriority: normalT-bugType: bugType: bug
Description
Component
Forge
Have you ensured that all of these are up to date?
- Foundry
- Foundryup
What version of Foundry are you on?
forge 0.1.0 (8a61027 2022-01-27T00:21:53.956016803+00:00)
What command(s) is the bug in?
forge test
Operating System
Linux
Describe the bug
We built a massive list of function signatures to use to decode data in stack traces. This worked fine before because we only decoded based on known contracts. Now we do it based on all functions. This causes an issue when two function have the same signature but have different outputs, i.e.: transfer() -> (uint256) and transfer() -> (uint256, uint256). One of these will fail and the trace will panic
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
C-forgeCommand: forgeCommand: forgeCmd-forge-testCommand: forge testCommand: forge testP-normalPriority: normalPriority: normalT-bugType: bugType: bug