I understand that ~/.zshenv gets sourced every time that an instance of zsh starts.
This implies that having the following line ~/.zshenv would result in an infinite regress:
(echo "$$ $(date)" >> $HOME/.debug.zshenv) ...because the (...) represents a subshell, and hence another sourcing of ~/.zshenv, etc.1
This reasoning notwithstanding, the line shown above is harmless, AFAICT. In particular, $HOME/.debug.zshenv shows only one line after I start a new shell with
% zsh Clearly, ~/.zshenv is not getting sourced anew when the line above is evaluated. Why not?
1For that matter, the expression $(date) also entails creating a subshell.