x
33
parameter (or (pair %transfer address mutez) (or (option %set_delegate key_hash) (unit %default)));storage address;code { UNPAIR ; IF_LEFT { UNPAIR ; DUP 3 ; SENDER ; COMPARE ; EQ ; IF {} { PUSH string "failed assertion" ; FAILWITH } ; CONTRACT unit ; IF_NONE { PUSH string "none" ; FAILWITH } {} ; SWAP ; UNIT ; TRANSFER_TOKENS ; SWAP ; NIL operation ; DIG 2 ; CONS } { IF_LEFT { DUP 2 ; SENDER ; COMPARE ; EQ ; IF {} { PUSH string "failed assertion" ; FAILWITH } ; SET_DELEGATE ; SWAP ; NIL operation ; DIG 2 ; CONS } { DROP ; NIL operation } } ; PAIR }