chore: Remove unused imports in normalized_shadow modules
Cleaned up unused imports after Phase 143 execution fix (5e662eaaf).
**Priority files (Phase 143)**:
- if_as_last_join_k.rs: removed ValueId, BTreeMap
- loop_true_break_once.rs: added #[cfg(test)] for test-only imports
- post_if_post_k.rs: removed ValueId, BTreeMap
- normalized_helpers.rs: added #[cfg(test)] for Span
**Additional cleanup**:
- contract_checks.rs: removed BasicBlockId
- joinir/mod.rs: removed Info struct re-exports (functions kept)
- patterns/mod.rs: removed Info struct re-exports (functions kept)
- ast_feature_extractor.rs: removed EscapeSkipPatternInfo
- plan_box.rs: added #[cfg(test)] for PlanKind
**Verification**:
- 0 unused import warnings (was 20+)
- All 69 normalized_shadow tests pass
- Clean build with --release
Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
@ -16,6 +16,13 @@ Related:
|
||||
- out-of-scope は `Ok(None)` でフォールバック(既定挙動不変)
|
||||
- effects の順序付けは SSOT で固定してから解禁(by-name 増殖禁止)
|
||||
|
||||
- **Phase 144-anf(planned): impure 式導入の順序固定(ANF)**
|
||||
- ねらい: `x + f(y)` 等の “pure + impure 混在” で評価順が仕様になる前に、ANF で順序固定を SSOT 化する
|
||||
- 入口: `docs/development/current/main/phases/phase-144-anf/INSTRUCTIONS.md`
|
||||
- 受け入れ条件:
|
||||
- impure を lowering できない場合は `Ok(None)` でフォールバック(既定挙動不変)
|
||||
- dev/strict では「順序固定の欠落」を Fail-Fast(診断に順序ログを含める)
|
||||
|
||||
- **Phase 143-loopvocab R0(planned): Contract SSOT 抽出(refactor P0 → modular components)**
|
||||
- 目的: loop_true_if_break_continue.rs を「検出/契約/変換」に分割し、P1/P2 での if分岐増殖を防ぐ
|
||||
- 実装:
|
||||
|
||||
@ -103,7 +103,7 @@ k_else(unused in P0)
|
||||
- `tools/smokes/v2/profiles/integration/apps/phase143_loop_true_if_break_vm.sh`
|
||||
- `tools/smokes/v2/profiles/integration/apps/phase143_loop_true_if_break_llvm_exe.sh`
|
||||
|
||||
Expected exit code: 1
|
||||
Expected exit code: 7
|
||||
|
||||
#### Step 9: Documentation (THIS FILE)
|
||||
|
||||
@ -134,6 +134,32 @@ Expected exit code: 1
|
||||
|
||||
---
|
||||
|
||||
## P1: Continue Vocabulary (COMPLETE ✅)
|
||||
|
||||
### Summary
|
||||
|
||||
`loop(true) { if(cond_pure) continue }` を語彙として受理し、Normalized shadow 経路で「コンパイル/実行が落ちない」ことを固定する。
|
||||
|
||||
### Important note (P1 scope)
|
||||
|
||||
P1 の fixture は **意図的に non-terminating**(break/else/state update を含まない)である。
|
||||
|
||||
- 条件式は `ExprLoweringScope::PureOnly` で lowering できることを検証する(スコープ境界の固定)。
|
||||
- ただし P1 では continue を「条件分岐で skip する」語彙までに留め、bridge 側の Jump(early-return) と混線させないため、
|
||||
実際の JoinIR emission は `loop_step` への tail call を基本にする。
|
||||
|
||||
### Fixture / smokes
|
||||
|
||||
- Fixture: `apps/tests/phase143_loop_true_if_continue_min.hako`
|
||||
- VM smoke (timeout contract):
|
||||
- `tools/smokes/v2/profiles/integration/apps/phase143_loop_true_if_continue_vm.sh`
|
||||
- Contract: `HAKO_VM_MAX_STEPS=0` + `timeout ${SMOKES_P143_CONTINUE_TIMEOUT_SECS:-1}` → exit code `124`
|
||||
- LLVM EXE smoke (timeout contract):
|
||||
- `tools/smokes/v2/profiles/integration/apps/phase143_loop_true_if_continue_llvm_exe.sh`
|
||||
- Contract: `RUN_TIMEOUT_SECS=${SMOKES_P143_CONTINUE_TIMEOUT_SECS:-1}` → exit code `124`
|
||||
|
||||
---
|
||||
|
||||
## Design Principles
|
||||
|
||||
### Out-of-Scope Handling
|
||||
|
||||
Reference in New Issue
Block a user