re-organized code so array specialization and comparison operators are
not in the same header, fixed swaping of deleters.