Fix Tovolar's Packleader (another-target subject stripping)#5880
Fix Tovolar's Packleader (another-target subject stripping)#5880e11734937-beep wants to merge 1 commit into
Conversation
The subject-strip dispatch gate `starts_with_subject_prefix`
(parser/oracle_effect/subject.rs) recognized the bare "target " subject
prefix but not "another target ". So an imperative effect whose subject
was "another target ..." was never subject-stripped: it fell through to
first-word dispatch on "another" and lowered to Effect::Unimplemented.
"Target creature phases out" parsed to Effect::PhaseOut, but "Another
target nonland permanent phases out" (The Phasing of Zhalfir, Chapter
I/II) did not.
Add "another target " as a sibling arm to the existing "target " arm.
The clause then routes through the same parse_subject_application
"another target" handler (which applies the Another / source-exclusion
filter property, exactly as the bare "target" sibling does) and the
existing imperative effect + runtime. No new effect variant and no
runtime path.
Flips three cards from unsupported to fully supported -- Tovolar's
Packleader ("{2}{G}{G}: Another target Wolf or Werewolf you control
fights target creature you don't control."), Cybernetica Datasmith
("Another target player creates a 4/4 ... Robot ... creature token"),
and Feral Contest ("Another target creature blocks it this turn if
able") -- and resolves the phase-out clause gap of The Phasing of
Zhalfir (gap_count 1 -> 0). Coverage 31351 -> 31354 supported, no
regressions.
Adds a discriminating integration test that drives the real cast ->
resolve -> PhaseOut pipeline via the phase-out variant (the cleanest
runtime-state delta); it fails on main, where the clause lowers to
Unimplemented and the target never phases out.
There was a problem hiding this comment.
Code Review
This pull request adds support for parsing "another target ..." subjects on imperative effects by adding the "another target " prefix to the subject-strip dispatch gate in the parser. This fixes a parser near-miss where such clauses fell through to first-word dispatch and resolved to Unimplemented, and a new integration test has been added to verify the fix. The review feedback correctly identifies a violation of Style Guide Rule R6, pointing out that the newly added parser arm is missing a mandatory CR annotation (CR 115.10a).
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
| // "another target X" mirrors the bare "target " arm below; the | ||
| // "another" source-exclusion is applied downstream in | ||
| // parse_subject_application (add_another_property). Without this arm, | ||
| // an imperative predicate on an "another target ..." subject (e.g. | ||
| // "another target nonland permanent phases out", The Phasing of | ||
| // Zhalfir) is not subject-stripped and falls through to first-word | ||
| // dispatch on "another", lowering to Unimplemented instead of | ||
| // reaching the existing effect. | ||
| value((), tag("another target ")), |
There was a problem hiding this comment.
Style Guide Violation: Missing CR Annotation
According to the repository style guide (R6. CR annotations are mandatory and verified), every rules-touching line of engine code must carry a comment of the form CR <number>: <description>.
Since this parser arm handles the "another target " prefix (which corresponds to CR 115.10a regarding the "another" target filter property), please prepend the CR 115.10a annotation to the comment.
| // "another target X" mirrors the bare "target " arm below; the | |
| // "another" source-exclusion is applied downstream in | |
| // parse_subject_application (add_another_property). Without this arm, | |
| // an imperative predicate on an "another target ..." subject (e.g. | |
| // "another target nonland permanent phases out", The Phasing of | |
| // Zhalfir) is not subject-stripped and falls through to first-word | |
| // dispatch on "another", lowering to Unimplemented instead of | |
| // reaching the existing effect. | |
| value((), tag("another target ")), | |
| // CR 115.10a: "another target X" mirrors the bare "target " arm below; the | |
| // "another" source-exclusion is applied downstream in | |
| // parse_subject_application (add_another_property). Without this arm, | |
| // an imperative predicate on an "another target ..." subject (e.g. | |
| // "another target nonland permanent phases out", The Phasing of | |
| // Zhalfir) is not subject-stripped and falls through to first-word | |
| // dispatch on "another", lowering to Unimplemented instead of | |
| // reaching the existing effect. | |
| value((), tag("another target ")), |
References
- R6. CR annotations are mandatory and verified. Every rules-touching line of engine code must carry a comment of the form CR : . (link)
Parse changes introduced by this PR · 5 card(s), 7 signature(s) (baseline: main
|
Summary
The subject-strip dispatch gate
starts_with_subject_prefix(parser/oracle_effect/subject.rs) recognized the baretargetsubject prefix but notanother target. An imperative effect whose subject wasanother target ...was therefore never subject-stripped: it fell through to first-word dispatch on "another" and lowered toEffect::Unimplemented. So "Target creature phases out" parsed toEffect::PhaseOut, but "Another target nonland permanent phases out" (The Phasing of Zhalfir) did not.This adds
another targetas a sibling arm to the existingtargetarm in the gate. The clause then routes through the sameparse_subject_application"another target" handler (which applies the Another / source-exclusion filter property viaadd_another_property, exactly as the bare "target" sibling does) and the existing imperative effect + runtime. No new effect variant and no new runtime path.Method: /engine-implementer
Track: Developer
Model: claude-opus-4-8, Thinking: high
Gate A PASS head=1bf1bfc370b3f27344c18f58820adbaeea8797fd base=553b97bd5c9f1a28bf7a6ebe80f6cb3a0e296c0d
Anchored on: subject.rs
tag("target ")sibling arm + subject.rs:2046parse_subject_application"another target" handler.Final review-impl PASS head=1bf1bfc370b3f27344c18f58820adbaeea8797fd
Claimed parse impact
Validation Failures: None
CI Failures: None