Commit Graph

2 Commits

Author SHA1 Message Date
2dfe363365 refactor(joinir): Phase 242-EX-A - Delete legacy Pattern3 lowerer
Remove hardcoded Pattern3 PoC implementation (loop_with_if_phi_minimal.rs)
and enhance if-sum mode to handle complex conditions like `i % 2 == 1`.

Key changes:
- condition_pattern.rs: Accept BinaryOp in comparison operands (+58 lines)
- loop_with_if_phi_if_sum.rs: Dynamic complex condition lowering (+147 lines)
- pattern3_with_if_phi.rs: Remove lower_pattern3_legacy() (-130 lines)
- loop_with_if_phi_minimal.rs: Delete entire file (-437 lines)
- loop_patterns/with_if_phi.rs: Update stub (-45 lines)
- mod.rs: Remove module reference (-4 lines)

Net reduction: -664 lines of hardcoded PoC code

Test results: 909/909 PASS (legacy mode completely removed)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-11 01:27:08 +09:00
a7dbc15878 feat(joinir): Phase 240-EX - Pattern2 header condition ExprLowerer integration
Implementation:
- Add make_pattern2_scope_manager() helper for DRY
- Header conditions use ExprLowerer for supported patterns
- Legacy fallback for unsupported patterns
- Fail-Fast on supported patterns that fail

Tests:
- 4 new tests (all pass)
- test_expr_lowerer_supports_simple_header_condition_i_less_literal
- test_expr_lowerer_supports_header_condition_var_less_var
- test_expr_lowerer_header_condition_generates_expected_instructions
- test_pattern2_header_condition_via_exprlowerer

Also: Archive old phase documentation (34k lines removed)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-11 00:33:04 +09:00