Skip to content

Commit

Permalink
test: recompile ERC3156FlashBorrowerMock with Remix
Browse files Browse the repository at this point in the history
  • Loading branch information
0xNeshi committed Dec 19, 2024
1 parent ee867fc commit 5f2f3f2
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions examples/erc20-flash-mint/tests/mock/borrower.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ use e2e::Wallet;

sol! {
#[allow(missing_docs)]
// Built with solc v0.8.24; solc examples/erc20-flash-mint/src/ERC3156FlashBorrowerMock.sol --via-ir --optimize --bin
#[sol(rpc, bytecode="60803461007e57601f61051038819003918201601f19168301916001600160401b0383118484101761008257808492604094855283398101031261007e57610052602061004b83610096565b9201610096565b15159060ff61ff005f5492151560081b1692169061ffff191617175f5560405161046c90816100a48239f35b5f80fd5b634e487b7160e01b5f52604160045260245ffd5b5190811515820361007e5756fe60806040818152600480361015610014575f80fd5b5f3560e01c6323e30c8b14610027575f80fd5b346102405760a0366003190112610240576001600160a01b03908035828116036102405760249182359081169182820361024057604435936084359667ffffffffffffffff90818911610240573660238a0112156102405788840135918211610240573683838b01011161024057853303610349575086516370a0823160e01b8152308482015260209890898185818a5afa908115610311575f9161031b575b5060607f6ff2acfcb07917b1e80e53f0fe390b467b1151d15b38730a6e08397799c05a8b918a5190898252308d8301528b820152a187516318160ddd60e01b8152898186818a5afa90811561031157918a918a94935f916102db575b5084516001600160a01b038916815260208101919091527f7249fd4c03cce09b30a13d77804b198e2647c0ccd59eadf4de4e7c16099badc59080604081015b0390a182610267575b5050505060ff5f54166101bc575b505050505060ff5f5460081c165f146101b5577f439148f0bbc682ca079e46d6e2c2f0c1e3b820f1a291b069d8882abf8cf18dd9905b51908152f35b5f906101af565b60643585018095116102555750845163095ea7b360e01b81526001600160a01b039092169082019081526020810193909352918491839182905f90829060400103925af1801561024b57610214575b80808080610179565b8281813d8311610244575b6102298183610381565b81010312610240575180151503610240575f61020b565b5f80fd5b503d61021f565b82513d5f823e3d90fd5b634e487b7160e01b5f90815260118352fd5b6102c9935f8094938461028661027d84976103b7565b94519485610381565b80845280898386019601863783010152519082885af13d156102d3573d906102ad826103b7565b916102ba8a519384610381565b82523d5f8b84013e5b856103d3565b50855f888161016b565b6060906102c3565b92809295508391503d831161030a575b6102f58183610381565b81010312610240575188928a91610162610123565b503d6102eb565b89513d5f823e3d90fd5b90508981813d8311610342575b6103328183610381565b81010312610240575160606100c7565b503d610328565b62461bcd60e51b815260208482015260158382015274496e76616c696420746f6b656e206164647265737360581b6044820152606490fd5b90601f8019910116810190811067ffffffffffffffff8211176103a357604052565b634e487b7160e01b5f52604160045260245ffd5b67ffffffffffffffff81116103a357601f01601f191660200190565b906103fa57508051156103e857805190602001fd5b60405163d6bda27560e01b8152600490fd5b8151158061042d575b61040b575090565b604051639996b31560e01b81526001600160a01b039091166004820152602490fd5b50803b1561040356fea2646970667358221220dba2e921315e51eaf012018f246989111ae3030fac9144486b91bb52f567dbb264736f6c63430008180033")]
contract ERC3156FlashBorrowerMock is IERC3156FlashBorrower {
// Built with Remix IDE; solc 0.8.24+commit.e11b9ed9 --optimization 200
#[sol(rpc, bytecode="60c060405234801561000f575f80fd5b5060405161069f38038061069f83398101604081905261002e91610051565b1515608052151560a052610082565b8051801515811461004c575f80fd5b919050565b5f8060408385031215610062575f80fd5b61006b8361003d565b91506100796020840161003d565b90509250929050565b60805160a0516105fc6100a35f395f6102f901525f61024b01526105fc5ff3fe608060405234801561000f575f80fd5b5060043610610029575f3560e01c806323e30c8b1461002d575b5f80fd5b61004061003b3660046104a7565b610052565b60405190815260200160405180910390f35b5f336001600160a01b038716146100a85760405162461bcd60e51b8152602060048201526015602482015274496e76616c696420746f6b656e206164647265737360581b60448201526064015b60405180910390fd5b6040516370a0823160e01b815230600482018190527f6ff2acfcb07917b1e80e53f0fe390b467b1151d15b38730a6e08397799c05a8b918891906001600160a01b038316906370a0823190602401602060405180830381865afa158015610111573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906101359190610545565b604080516001600160a01b0394851681529390921660208401529082015260600160405180910390a17f7249fd4c03cce09b30a13d77804b198e2647c0ccd59eadf4de4e7c16099badc586876001600160a01b03166318160ddd6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156101bc573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906101e09190610545565b604080516001600160a01b03909316835260208301919091520160405180910390a18115610249576102478684848080601f0160208091040260200160405190810160405280939291908181526020018383808284375f9201919091525061034f92505050565b505b7f0000000000000000000000000000000000000000000000000000000000000000156102f7576001600160a01b03861663095ea7b387610289878961055c565b6040516001600160e01b031960e085901b1681526001600160a01b03909216600483015260248201526044016020604051808303815f875af11580156102d1573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906102f5919061057b565b505b7f0000000000000000000000000000000000000000000000000000000000000000610322575f610344565b7f439148f0bbc682ca079e46d6e2c2f0c1e3b820f1a291b069d8882abf8cf18dd95b979650505050505050565b606061035c83835f610365565b90505b92915050565b6060814710156103915760405163cf47918160e01b81524760048201526024810183905260440161009f565b5f80856001600160a01b031684866040516103ac919061059a565b5f6040518083038185875af1925050503d805f81146103e6576040519150601f19603f3d011682016040523d82523d5f602084013e6103eb565b606091505b50915091506103fb868383610407565b925050505b9392505050565b60608261041c5761041782610463565b610400565b815115801561043357506001600160a01b0384163b155b1561045c57604051639996b31560e01b81526001600160a01b038516600482015260240161009f565b5080610400565b8051156104735780518082602001fd5b60405163d6bda27560e01b815260040160405180910390fd5b80356001600160a01b03811681146104a2575f80fd5b919050565b5f805f805f8060a087890312156104bc575f80fd5b6104c58761048c565b95506104d36020880161048c565b94506040870135935060608701359250608087013567ffffffffffffffff808211156104fd575f80fd5b818901915089601f830112610510575f80fd5b81358181111561051e575f80fd5b8a602082850101111561052f575f80fd5b6020830194508093505050509295509295509295565b5f60208284031215610555575f80fd5b5051919050565b8082018082111561035f57634e487b7160e01b5f52601160045260245ffd5b5f6020828403121561058b575f80fd5b81518015158114610400575f80fd5b5f82515f5b818110156105b9576020818601810151858301520161059f565b505f92019182525091905056fea264697066735822122072bcfdbac0cd2f50d6eb0f6c882d0babb57a52e62164f6dd7962b0938dbc2ac364736f6c63430008180033")]
contract ERC3156FlashBorrowerMock {
bytes32 internal constant _RETURN_VALUE =
keccak256("ERC3156FlashBorrower.onFlashLoan");

bool _enableApprove;
bool _enableReturn;
bool immutable _enableApprove;
bool immutable _enableReturn;

#[derive(Debug, PartialEq)]
event BalanceOf(address token, address account, uint256 value);
Expand Down

0 comments on commit 5f2f3f2

Please sign in to comment.