Analyticity results for the Euler and Navier-Stokes equations