fix contract
Fix implicit tuples generation. Should now work in all cases.