Phase 12.7文法改革: ドキュメント文法統一 + VMリファクタリング準備

🌟 Phase 12.7文法改革に基づくドキュメント更新
- init {} → field: TypeBox 個別フィールド宣言形式
- init() → birth() コンストラクタ統一
- pack() → 廃止(birth()に統一)
- public {}/private {} → 個別フィールド修飾子
- override → 廃止(メソッド定義はシンプルに)

📚 更新したドキュメント
- CLAUDE.md: メイン開発ガイド
- docs/quick-reference/syntax-cheatsheet.md: 構文早見表
- docs/reference/language/LANGUAGE_REFERENCE_2025.md: 言語リファレンス
- docs/development/roadmap/phases/phase-15/README.md: Phase 15計画

🔧 VMリファクタリング準備
- vm_methods.rs: VMメソッド呼び出しの分離
- plugin_loader.rs → plugin_loader/: ディレクトリ構造化
- mir/builder/exprs.rs: 式ビルダー分離

📝 新規ドキュメント追加
- 論文戦略・ロードマップ
- Phase 15セルフホスティング準備資料
- Codex Androidセットアップガイド

ビルドは正常に通ることを確認済み!🎉

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

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Moe Charm
2025-09-04 06:27:39 +09:00
parent 6488b0542e
commit 4e824fa00e
27 changed files with 2804 additions and 1656 deletions

View File

@ -13,14 +13,13 @@ local x = 10, y = 20, z # 混合初期化
### Box定義クラス
```nyash
box ClassName {
init { field1, field2 } # フィールド宣言(形式)
# フィールド宣言(Phase 12.7形式)
field1: TypeBox # デフォルト非公開
public field2: TypeBox # 公開フィールド
private field3: TypeBox # 明示的非公開
# または新形式(推奨
public { name, age } # 公開フィールド
private { password } # 非公開フィールド
init(args) { # コンストラクタ
me.name = args
birth(args) { # コンストラクタbirth統一
me.field1 = args
}
}
```
@ -28,7 +27,7 @@ box ClassName {
### Static Boxエントリーポイント
```nyash
static box Main {
init { console }
console: ConsoleBox
main() {
me.console = new ConsoleBox()
@ -70,11 +69,11 @@ loop() { } # エラー!
### 基本デリゲーション
```nyash
box Child from Parent {
init(args) {
from Parent.init(args) # 親の初期化
birth(args) {
from Parent.birth(args) # 親のbirth呼び出し
}
override method() { # オーバーライド必須
method() { # メソッド定義
from Parent.method() # 親メソッド呼び出し
}
}