diff options
| author | Paul Buetow <paul@buetow.org> | 2026-05-23 22:11:02 +0300 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2026-05-23 22:11:02 +0300 |
| commit | a0da020a99a9ded8c7f4f79aebb689ee300c769d (patch) | |
| tree | e568eb5e6e4d3a910cb2e37a66ad521f61a59e20 /cmd | |
| parent | 1179c247afbc815a664e26fd58a52f75bec15ccd (diff) | |
refactor: fix parseCategory OCP violation with range-based iteration
Replace the switch/case in parseCategory() with range-based iteration
over all Category constants (Universal through _sentinel). This achieves
true OCP compliance: adding a new Category constant before _sentinel
automatically makes it available in parseCategory without modifying the
function.
Added _sentinel constant as the upper bound for range-based iteration,
with a comment explaining how to add new categories correctly.
Diffstat (limited to 'cmd')
0 files changed, 0 insertions, 0 deletions
