Ensures better memory safety for this global. This came up during
discussion of the following commit, but is not strictly required for its
implementation.
This is a partial backport of core#27125
https://github.com/bitcoin/bitcoin/pull/27125/commits/8ed4ff8e05d61a8e954d72cebdc2e1d1ab24fb84