Sort iterations over functions by (name, address)