add ndim to both Expr and DistArray