0

Are UniSwap V2 flash-swaps stored the same way "normal" swaps are stored? I.e. are they recorded under the "Swap" event on the blockchain?

Context: I'm trying to reproduce the volume figures in table 1 of this paper by Lehar and Parlour on decentralized exchanges and the authors note that they also include flash swaps in their volume calculations.

1

1 Answer 1

1

Yes, a flash swap will trigger the same events as a normal swap.

The only difference is that in a flash swap, the contract that called the swap can perform some arbitrary code between the moment it receives tokens from the pair and the moment that the swap function checks if it received enough input token (the calculation of the k constant).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.