Macy's slashes its full-year outlook even as earnings beat