If every functional of $f$ is smooth, is $f$ smooth? Let E be a (real or complex) Banach space and suppose $f: \mathbb{R}^n \rightarrow E$ has the property that $\lambda \circ f$ is $C^\infty$ for every bounded linear functional $\lambda \in E^\ast$.  Does it follow that $f$ is also $C^\infty$?
I didn't really encounter this question anywhere; it occurred to me while reading about smooth, Banach space valued functions.  I remembered that all weakly holomorphic Banach space valued functions are holomorphic and I thought it would be nice to have a similar criterion for smooth functions.

See Theorem 5.0.3 in these notes by Paul Garrett, where this is shown for weakly smooth $f$ on a closed real interval.
It seems he isn't using anything specific to the fact that $f$ is defined on a dimension $1$ space, so I think the proof generalizes to $\mathbb R^n$.
