All evidence cases
DeepSWE v1.1repositoryTypeScript

Add `matchEach` to ts-pattern

Add a new `matchEach` matcher that evaluates all matching clauses and returns all results in order.

ts-pattern-match-each

Normalized profile

What this task asks for

Add a new `matchEach` matcher that evaluates all matching clauses and returns all results in order. `matchEach` must expose the same builder API as `match`, including all `.with()` overloads (single pattern, multi-pattern, and guard variants), `.when()`, `.returnType()`, and `.narrow()`. Unlike `match`, every `.with()` call must accept patterns against the original input type (not the progressively narrowed remainder), since all branches are always evaluated. Exhaustiveness tracking should still narrow the internal type so `.exhaustive()` can verify all cases are handled, while `.narrow()` updates both the internal tracking type and the input type for subsequent calls to exclude handled cases. `.exhaustive()` additionally enforces compile-time exhaustiveness: it should be a type error if not all input cases are handled. `.toExhaustiveFunction()` behaves the same but additionally enforces compile-time exhaustiveness: it should be a type error if not all input cases are handled. Selections via `P.select()` must produce independent results across multiple calls of any compiled function.

  • feature implementation
  • configuration tuning
  • compiler
  • runtime
  • library API
  • build system
  • ts-pattern
  • repository patch
  • native compilation and dependency integration
  • changes span multiple components or interfaces

Published evidence

Model × harness outcomes

Counts are tied to these exact configurations. Harnesses are not treated as equivalent across benchmarks.

Models
13
Configurations
41
Trials
164

Showing 41 of 41 configurations

ModelHarnessEffortResultPasses
claude-fable-5vertex_aimini-swe-agentpublished configurationlowAll passed4/4
claude-fable-5vertex_aimini-swe-agentpublished configurationmediumAll passed4/4
claude-fable-5vertex_aimini-swe-agentpublished configurationhighMixed2/4
claude-fable-5vertex_aimini-swe-agentpublished configurationxhighAll passed4/4
claude-fable-5vertex_aimini-swe-agentpublished configurationmaxAll passed4/4
claude-opus-4-8anthropicmini-swe-agentpublished configurationlowMixed2/4
claude-opus-4-8anthropicmini-swe-agentpublished configurationmediumMixed1/4
claude-opus-4-8anthropicmini-swe-agentpublished configurationhighMixed2/4
claude-opus-4-8anthropicmini-swe-agentpublished configurationxhighMixed3/4
claude-opus-4-8anthropicmini-swe-agentpublished configurationmaxMixed2/4
claude-sonnet-4-6anthropicmini-swe-agentpublished configurationhighMixed3/4
claude-sonnet-5anthropicmini-swe-agentpublished configurationlowMixed2/4
claude-sonnet-5anthropicmini-swe-agentpublished configurationmediumMixed3/4
claude-sonnet-5anthropicmini-swe-agentpublished configurationhighMixed3/4
claude-sonnet-5anthropicmini-swe-agentpublished configurationxhighAll passed4/4
claude-sonnet-5anthropicmini-swe-agentpublished configurationmaxAll passed4/4
gemini-3-1-pro-previewvertex_aimini-swe-agentpublished configurationhighAll passed4/4
gemini-3-5-flashvertex_aimini-swe-agentpublished configurationmediumAll passed4/4
glm-5-2zaimini-swe-agentpublished configurationhighMixed2/4
glm-5-2zaimini-swe-agentpublished configurationmaxMixed2/4
gpt-5-4openaimini-swe-agentpublished configurationxhighMixed2/4
gpt-5-5openaimini-swe-agentpublished configurationlowMixed1/4
gpt-5-5openaimini-swe-agentpublished configurationmediumAll passed4/4
gpt-5-5openaimini-swe-agentpublished configurationhighAll passed4/4
gpt-5-5openaimini-swe-agentpublished configurationxhighMixed3/4
gpt-5-6-lunaopenaimini-swe-agentpublished configurationlowNo passes0/4
gpt-5-6-lunaopenaimini-swe-agentpublished configurationmediumMixed2/4
gpt-5-6-lunaopenaimini-swe-agentpublished configurationhighMixed3/4
gpt-5-6-lunaopenaimini-swe-agentpublished configurationxhighMixed3/4
gpt-5-6-lunaopenaimini-swe-agentpublished configurationmaxMixed3/4
gpt-5-6-solopenaimini-swe-agentpublished configurationlowMixed2/4
gpt-5-6-solopenaimini-swe-agentpublished configurationmediumMixed3/4
gpt-5-6-solopenaimini-swe-agentpublished configurationhighMixed2/4
gpt-5-6-solopenaimini-swe-agentpublished configurationxhighMixed3/4
gpt-5-6-solopenaimini-swe-agentpublished configurationmaxMixed3/4
gpt-5-6-terraopenaimini-swe-agentpublished configurationlowMixed3/4
gpt-5-6-terraopenaimini-swe-agentpublished configurationmediumAll passed4/4
gpt-5-6-terraopenaimini-swe-agentpublished configurationhighAll passed4/4
gpt-5-6-terraopenaimini-swe-agentpublished configurationxhighAll passed4/4
gpt-5-6-terraopenaimini-swe-agentpublished configurationmaxAll passed4/4
kimi-k2-7-codeopenroutermini-swe-agentpublished configurationdefaultMixed1/4