docs(repl): record Phase 288.1 contract and results
更新内容: - docs/reference/language/repl.md - Phase 288.1 完了ステータスに更新 - Implementation Architecture セクション追加(AST rewrite 方式説明) - AST Rewriter の動作フロー追加(Variable/Assignment 変換ロジック) - ExternCall Bridge の仕組み追加(__repl.get/set → VMValue) - Expression Detection ロジック追加(wrapper AST 判定) - 動作例を完全に更新(全機能が動作済み) - docs/development/current/main/phases/phase-288/README.md - Phase 288.1 完了セクション追加 - 変更ファイル一覧(8ファイル, +592行)記録 - 確認コマンド 4種 記録(変数永続化/式表示/_変数/リセット) - 回帰テスト結果記録(154/154 PASS) - docs/development/current/main/10-Now.md - "Phase 288.1 完了" に更新 - 次の候補(REPL UX 改善 / JoinIR 設計作業)を追記 - CURRENT_TASK.md - 1段落サマリー更新(288.1 完了、次の方向性) Phase 288.1 成果(SSOT記録): ✅ 変数永続化(session → eval bridge) ✅ 式自動表示(pure expression auto-output) ✅ _ 変数(last displayed value) ✅ Fail-Fast 未定義エラー + ヒント ✅ セッションリセット(.reset) ✅ 154/154 smoke tests PASS(file mode 不変) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
@ -2,20 +2,42 @@
|
||||
|
||||
## Current Focus (next)
|
||||
|
||||
- Phase 288.1(dev-tools): REPL session persistence + auto-display
|
||||
- 目的: `hakorune --repl` で変数が行を跨いで生きる(暗黙local)+式の自動表示(`_` を含む)
|
||||
- 入口: `docs/development/current/main/phases/phase-288/README.md`
|
||||
- 手順: `docs/development/current/main/phases/phase-288/P1-INSTRUCTIONS.md`
|
||||
**2025-12-25: Phase 288.1 完了** ✅
|
||||
- REPL session persistence + auto-display 実装完了
|
||||
- AST rewrite 方式(__repl.get/set ExternCall)
|
||||
- 154/154 smoke tests PASS(file mode 不変)
|
||||
- 詳細: `docs/development/current/main/phases/phase-288/README.md`
|
||||
|
||||
- Phase 284(design-first): Return as ExitKind SSOT(patternに散らさない)
|
||||
- 目的: `return` を `ExitKind` + `compose::*` / `emit_frag()` に収束させ、pattern側の個別実装を増やさない
|
||||
- 入口: `docs/development/current/main/phases/phase-284/README.md`
|
||||
- 手順: `docs/development/current/main/phases/phase-284/P0-INSTRUCTIONS.md`
|
||||
- 次: Phase 285(design-first)Box lifecycle SSOT(`docs/development/current/main/phases/phase-285/README.md`)
|
||||
- 次の次: Phase 286(design-first)JoinIR line absorption(`docs/development/current/main/phases/phase-286/README.md`)
|
||||
**次の候補**:
|
||||
1. **Phase 288.2+** (REPL UX improvements): Multi-line input, syntax highlighting, history
|
||||
2. **Phase 284** (design-first): Return as ExitKind SSOT
|
||||
- 入口: `docs/development/current/main/phases/phase-284/README.md`
|
||||
- 手順: `docs/development/current/main/phases/phase-284/P0-INSTRUCTIONS.md`
|
||||
3. **JoinIR/slot improvements**: Phase 285/286 継続
|
||||
- Phase 285: Box lifecycle SSOT
|
||||
- Phase 286: JoinIR line absorption
|
||||
|
||||
## Recently Completed
|
||||
|
||||
### 2025-12-25: Phase 288.1(REPL Session Persistence + Auto-Display)
|
||||
|
||||
- ✅ **Phase 288.1完了**: REPL variable persistence + expression auto-display
|
||||
- 詳細: `docs/development/current/main/phases/phase-288/README.md`
|
||||
- 実装方式: AST Rewrite + ExternCall Bridge
|
||||
- 達成内容:
|
||||
- ✅ AST Rewriter 実装(~430行、`src/runner/repl/ast_rewriter.rs`)
|
||||
- ✅ __repl.get/set ExternCall handlers 実装
|
||||
- ✅ Rc<RefCell<ReplSessionBox>> session sharing
|
||||
- ✅ Expression auto-display + `_` variable
|
||||
- ✅ Fail-fast undefined variable errors
|
||||
- 検証結果:
|
||||
- ✅ Variable persistence: `x = 42` then `print(x)` → `42`
|
||||
- ✅ Expression display: `1 + 1` → `2`
|
||||
- ✅ `_` variable: `10 * 2` → `20`, then `_` → `20`
|
||||
- ✅ Session reset: `.reset` clears all variables
|
||||
- ✅ 154/154 smoke tests PASS (no regressions)
|
||||
- Files: 8 files, +592 lines (REPL-isolated)
|
||||
|
||||
### 2025-12-24: Phase 285LLVM-1.3(LLVM InstanceBox Field Access)
|
||||
|
||||
- ✅ **Phase 285LLVM-1.3完了**: InstanceBox field access (getField/setField) implementation
|
||||
|
||||
Reference in New Issue
Block a user