You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When a contract deployment fails in Create2, returndata is ignored even though it may contain a revert reason that should probably be bubbled up like the Address library does for calls. I haven't checked if Solidity does this for native contract creation.
The result is that Some message is shown in the console.
Reason provided by the contract: "Some message".
Although it seems to be the default behavior in Solidity, this is one of those cases where bubbling up the revert reason adds an extra instruction that nobody asked for 🤔.
Although factories should rely mostly on Clones for deterministic deployments instead of Create2, I wonder if there's a use case we this extra instruction would represent significative costs.
When a contract deployment fails in
Create2
, returndata is ignored even though it may contain a revert reason that should probably be bubbled up like theAddress
library does for calls. I haven't checked if Solidity does this for native contract creation.openzeppelin-contracts/contracts/utils/Create2.sol
Line 49 in 255e27e
The text was updated successfully, but these errors were encountered: