Page MenuHomePhabricator

refactor: make MainSignalsInstance() a class, rename it to MainSignalsImpl
ClosedPublic

Authored by PiRK on Mar 10 2023, 08:24.

Details

Summary

refactor: make MainSignalsInstance() a class

Context:

MainSignalsInstance was originally a struct collection of boost::signals methods moved to validationinterface.cpp, in order to no longer need to include boost/signals in validationinterface.h.

MainSignalsInstance then evolved to remove boost/signals2 and became class-like.

C.8: Use class rather than struct if any member is non-public

C.2: Use class if the class has an invariant; use struct if the data members can vary independently

A class also has the advantage of default private access, as opposed to public for a struct.

refactor: remove unused forward declarations in validationinterface.h

Rename MainSignalsInstance() class to MainSignalsImpl()

This is a backport of core#25067

Test Plan

ninja all check-all

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable