[C++] Introduce ScopedTerminator
3 files changed