-
Notifications
You must be signed in to change notification settings - Fork 29
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
New Daimo Pay contracts to support bridging with across #1353
base: internal
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
import "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; | ||
|
||
/// @notice Bridges assets automatically. Specifically, it lets any market maker | ||
/// initiate a bridge transaction to another chain. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔥
function addressToBytes32(address addr) internal pure returns (bytes32) { | ||
return bytes32(uint256(uint160(addr))); | ||
} | ||
|
||
function bytes32ToAddress(bytes32 b) internal pure returns (address) { | ||
return address(uint160(uint256(b))); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
currently specific to CCTP
can delete here
potentially, we can move these to IDaimoPayBridger.sol & generalize that interface to allow 32-byte addresses. this would let us support intents where the destination is eg. on solana, or intents where someone's paying from solana etc
intentAddr: address(intentContract), | ||
finalRecipient: recipient, | ||
intent: intent | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚀
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGreatTM after comments
Left to do ~
- Across decision
- DaimoPayLP testing
- Test deployment on mainnet base+op+linea
23ea94d
to
576fe76
Compare
No description provided.