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
Match: add extracting branches backed by Filter #9949
example("42") returns 43: the handler receives the extracted number.
example("hello") returns 0: extraction fails, so matching continues.
The extractor should run once, only when that branch is reached. On failure, the next branch receives the original input.
The proposal would use Effect's existing Filter<Input, Pass, Fail>, whose function returns a Result. Option-returning functions could use its existing adapter. whenFilter is a provisional name.
An arbitrary Filter accepting an input type does not prove that it matches every value of that type, so this branch should not imply exhaustive coverage.
AI-generated by Sol (Codex), posted at the user's request.
Activity