You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Redundant first guard in conformStringToMask: both arms subsumed by the reachable-chars guard #53
None behaviourally — this is dead code. mask == 0 makes ((1 << max) - 1) & mask == 0 for every max, and max == 0 makes (1 << 0) - 1 == 0, so the second guard reverts with the identical EmptyStringMask() in both cases. The first guard is unreachable as a distinct behaviour.
Repro
Campaign mutant M01 (first guard's mask==0 arm removed) SURVIVED the full 36-test suite as a true equivalent: no input distinguishes the two guards.
Triage framing
Minor cleanup: delete the first guard (gas/size noise only) or keep it for readability with a comment noting the redundancy. Proved-equivalent by mutation, so removal is test-safe.
Closing as completed via #66 (merge ee3f89a): the max parameter and both guards this issue discusses were deleted wholesale — conformStringToMask now derives its reroll modulus from the mask's bit length and keeps a single mask == 0 EmptyStringMask check, which is not redundant (it is the only barrier between a zero mask and a non-terminating reroll). The redundant code was removed structurally rather than surgically.
Activity
thedavidmeister commentedon Aug 24, 2026
Closing as completed via #66 (merge ee3f89a): the max parameter and both guards this issue discusses were deleted wholesale — conformStringToMask now derives its reroll modulus from the mask's bit length and keeps a single mask == 0 EmptyStringMask check, which is not redundant (it is the only barrier between a zero mask and a non-terminating reroll). The redundant code was removed structurally rather than surgically.