starting to add a generic swap
use generic swap for complex numbers