📚 Phase 173 前半完了(Task 1-3)! ✅ Task 1: 名前解決経路調査 - UsingResolverBox / CalleeResolverBox 構造把握 - 3つの重大問題発見: 1. 静的 Box が InstanceBox として扱われる 2. JsonParserBox _parse_number 無限ループ 3. new Alias.BoxName() 構文未サポート ✅ Task 2: 仕様固定(docs) - using.md: +179行(静的 Box 使用例) - LANGUAGE_REFERENCE_2025.md: +54行(static box ライブラリ方針) ✅ Task 3: JsonParserBox バグ修正 - MIR Nested-If-in-Loop Bug 発見・回避 - while → loop() 構文統一(10箇所) - ネスト if-else のフラット化 📋 成果物: - phase173_task1_investigation.md(220行) - phase173_using_static_box_resolution.md - phase173-2_using_resolver_mir_lowering.md(後半指示書) - mir-nested-if-loop-bug.md(バグ分析) - json_parser_min.hako(テストファイル) 🎯 次: Task 4-6(using resolver + MIR lowering 統合) 🤖 Generated with Claude Code Co-Authored-By: Claude <noreply@anthropic.com>
Nyash Language Reference – Index
This is the entry point for Nyash language documentation.
- Full Language Reference (2025): reference/language/LANGUAGE_REFERENCE_2025.md
- Syntax Cheat Sheet: quick-reference/syntax-cheatsheet.md
- Phase 12.7 Grammar Specs (ternary, sugar; peek → match に統合):
- Overview: development/roadmap/phases/phase-12.7/grammar-specs/README.md
- Token/Grammar: development/roadmap/phases/phase-12.7/ancp-specs/ANCP-Token-Specification-v1.md
- Sugar Transformations (?., ??, |> and friends): parser/sugar.rs (source) and tools/nyfmt/NYFMT_POC_ROADMAP.md
- Match Expression (pattern matching): see the Language Reference and EBNF (peek was replaced by match)
Statement separation and semicolons
- See: reference/language/statements.md — newline as primary separator; semicolons optional for multiple statements on one line; minimal ASI rules.
Imports and namespaces
- See: reference/language/using.md —
usingsyntax, runner resolution, and style guidance.
Variables and scope
- See: reference/language/variables-and-scope.md — Block-scoped locals, assignment resolution, and strong/weak reference guidance.
Grammar (EBNF)
- See: reference/language/EBNF.md — Stage‑2 grammar specification used by parser implementations.
- Unified Members (stored/computed/once/birth_once): see reference/language/EBNF.md “Box Members (Phase 15)” and the Language Reference section. Default ON (disable with
NYASH_ENABLE_UNIFIED_MEMBERS=0).
Member exceptions and handlers (Stage‑3)
- Postfix
catch/cleanupmay be attached to computed/once/birth_once/method blocks when Stage‑3 is enabled. Stored members (plainname: Type [= expr]) do not support handlers.
Related implementation notes
- Tokenizer: src/tokenizer.rs
- Parser (expressions/statements): src/parser/expressions.rs, src/parser/statements.rs
- MIR Lowering (expressions): src/mir/builder/exprs.rs and friends
Navigation tips
- The “reference/language/LANGUAGE_REFERENCE_2025.md” is the canonical long‑form reference; use the Cheat Sheet for quick syntax lookup.
- Phase 12.7 files capture the finalized sugar and new constructs (match (replaces peek), ternary, null‑safe).