Function: completeTokenSwap(ExternalTrade[] externalTrades)
This function completes the token swaps by claiming the tokens from the CoWSwapClone contracts.
Inputs
externalTrades
Control: Fully controlled by the caller.
Constraints: None at this level.
Impact: The external trades that were executed are used to claim the tokens.
Branches and code coverage
Intended branches
Call
claim
on each CoWSwapClone contract.
Function call analysis
CoWSwapClone(swapContract).claim()
What is controllable?
swapContract
. The address is determined by thekeccak256
hash of the external trade details.If the return value is controllable, how is it used and how can it go wrong? The return value is used to store the claimed amounts of the sell and buy tokens. It is used to emit an event.
What happens if it reverts, reenters or does other unusual control flow? N/A.