feat(parser): compound-subject land type-change static (CR 611.3 / CR 305.7)#5296
Conversation
… 305.7) Adds parse_compound_all_subjects_land_type_change mirroring the phase-rs#5219 compound animation structure: Or-distributed subjects via parse_compound_all_subjects_filter and a single predicate parsed through a factored parse_land_type_change_modifications helper. Closes phase-rs#5294
There was a problem hiding this comment.
Code Review
This pull request introduces support for parsing compound-subject land type-changing static abilities (e.g., 'All Mountains and all Forests are Plains') under CR 611.3 and CR 305.7. It refactors the existing single-subject land type-change parser to extract predicate parsing into a shared helper, parse_land_type_change_modifications, which is then reused by a new compound-subject parser parse_compound_all_subjects_land_type_change. Comprehensive unit tests were also added to verify both replacement and additive predicates. There are no review comments, and I have no feedback to provide.
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.
Parse changes introduced by this PR✓ No card-parse changes detected. |
matthewevans
left a comment
There was a problem hiding this comment.
Reviewed the parser seam and changed files against the phase.rs review bar. The implementation reuses the compound-subject filter and shared land-type predicate lowering, CR 611.3/305.7/205.1b citations resolve locally, GitHub CI is green, and the required parse-diff sticky reports no current card-parse changes.
Summary
Mirrors the structural pattern from #5219 (compound-subject static dispatch) for the land type-change axis:
parse_compound_all_subjects_land_type_changeintype_change.rsparse_compound_all_subjects_filterforOrsubject distribution (CR 611.3)parse_land_type_change_modifications, shared withparse_land_type_changeparse_land_animation/ single-subjectparse_land_type_change"creature"gate keeps animation compounds (Life and Limb) on the animation pathCloses #5294
Files changed
crates/engine/src/parser/oracle_static/type_change.rscrates/engine/src/parser/oracle_static/dispatch.rscrates/engine/src/parser/oracle_static/tests.rsTest plan
cargo fmt --all— cleancargo check -p engine— cleancargo test -p engine --lib parser::oracle_static— blocked locally by Windows linker; CI should verifyAll Mountains and all Forests are Plains.→Or+SetBasicLandType… Swamps in addition to their other land types→AddSubtype