It's the `${` that objects to the space. It must be immediately followed by a parameter name, another substitution, a command substitution, or a parenthesized list of flags which is itself immediately followed by a parameter name, another substitution, or a command substitution. None of these allow a space at their beginning.
All of the following are valid:
% echo ${ZSH_VERSION}
5.9
% echo ${${ZSH_VERSION}}
5.9
% echo ${$(echo $ZSH_VERSION)}
5.9
% echo ${(f)ZSH_VERSION}
5.9
% echo ${(f)${ZSH_VERSION}}
5.9
% echo ${(f)$(echo $ZSH_VERSION)}
Add a space after the `${` or after its list of flags and all of them become invalid:
% echo ${ ZSH_VERSION}
zsh: bad substitution
% echo ${ ${ZSH_VERSION}}
zsh: bad substitution
% echo ${ $(echo $ZSH_VERSION)}
zsh: bad substitution
% echo ${(f) ZSH_VERSION}
zsh: bad substitution
% echo ${(f) ${ZSH_VERSION}}
zsh: bad substitution
% echo ${(f) $(echo $ZSH_VERSION)}
Philippe