ocp-composition-with-principled-escape

Status: IN

OCP's historical evolution from inheritance to abstraction validates composition as the default extension paradigm, while Visitor's double-dispatch mechanism provides a principled OCP axis inversion for operation-extensible designs — the composition paradigm explicitly accommodates its own exceptions rather than being an absolute rule.

Justifications

Both depth-2 conclusions address OCP's relationship to composition from opposite directions (evolution toward it, deliberate inversion of it); together they reveal composition as a default-with-escape-hatch rather than a dogma

Depends on (SL): ocp-evolution-validates-composition-shift, visitor-dispatch-implements-ocp-inversion

Depended on by

JSON