b003bdf25b
📚 Phase 11 documentation: Everything is Box × MIR15 revolution
...
Key updates:
- Document MIR 26→15 instruction reduction plan (transitioning status)
- Add Core-15 target instruction set in INSTRUCTION_SET.md
- Save AI conference analyses validating Box Theory and 15-instruction design
- Create MIR annotation system proposal for optimization hints
- Update SKIP_PHASE_10_DECISION.md with LLVM direct migration rationale
Technical insights:
- RefNew/RefGet/RefSet can be eliminated through Box unification
- GC/sync/async all achievable with 15 core instructions
- BoxCall lowering can automatically insert GC barriers
- 2-3x performance improvement expected with LLVM
- Build time reduction 50%, binary size reduction 40%
Status: Design complete, implementation pending
2025-08-31 03:03:04 +09:00
eedfcedc61
Add string_bridge_full.nyash rich demo and enhance e2e script color/auto bin selection; keep VM/AOT flow intact
2025-08-31 00:22:55 +09:00
4ae92cfb56
Phase 10.7/10.5c: include cycle detection (VM/Interpreter), minimal pyc IR→Nyash, String unification bridge (VM partial), add core plugins: RegexBox/EncodingBox/TOMLBox/PathBox + examples; wire nyash.toml; begin String interop for internal vs plugin boxes; update CURRENT_TASK.md
2025-08-30 23:47:08 +09:00
c13d9c045e
📚 Phase 12: Nyashスクリプトプラグインシステム設計と埋め込みVM構想
...
## 主な成果
- Nyashスクリプトでプラグイン作成可能という革命的発見
- C ABI制約の分析と埋め込みVMによる解決策
- MIR/VM/JIT層での箱引数サポートの詳細分析
## ドキュメント作成
- Phase 12基本構想(README.md)
- Gemini/Codex先生の技術分析
- C ABIとの整合性問題と解決策
- 埋め込みVM実装ロードマップ
- 箱引数サポートの技術詳細
## 重要な洞察
- 制約は「リンク時にC ABI必要」のみ
- 埋め込みVMでMIRバイトコード実行により解決可能
- Nyashスクリプト→C ABIプラグイン変換が実現可能
Everything is Box → Everything is Plugin → Everything is Possible!
2025-08-30 22:52:16 +09:00
7a0f9bd432
🚨 AI協調開発の危機回避事例を論文化(paper-09)
...
「ん?大丈夫?」の一言がPython特化ハードコーディングを防いだ事例を記録。
Everything is Box哲学 vs 技術的正しさの綱渡りからの生還を分析。
- docs/research/paper-09-ai-collaboration-pitfall/ を新規作成
- incident-analysis.md: Lowerer特殊化危機の詳細分析
- ai-collaboration-lessons.md: AI協調開発の教訓
- intuition-in-engineering.md: エンジニアの直感の価値
- summary.md: 綱渡りからの生還まとめ
- 研究論文の1論文1フォルダ原則に従い整理
- Python統合関連の実装修正とビルド成功確認
🛡️ Generated with Claude Code
2025-08-30 08:54:15 +09:00
db265d7f29
🐍 Python統合をAOTレベルまで完成(eval方式でunsupported=0達成)
...
- PyRuntimeBox.eval() で完全AOT対応(FloatBox返却)
- NYASH_PY_AUTODECODE=1 によるプリミティブ型自動変換
- ConsoleBox経由の出力もAOT対応
- 多数のPythonテストサンプル追加
- 論文「1ヶ月でインタープリターからネイティブまで」執筆開始
課題:
- import/getattr/callはプラグイン側の実装待ち
- importとevalの文脈共有は未対応
🤖 Generated with [Claude Code](https://claude.ai/code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-30 07:47:21 +09:00
1b98f85df9
🚀 Phase 10.11: Everything is Plugin革命完了!
...
主な変更:
- ConsoleBox/MathBoxプラグイン実装・登録完了
- nyash_box.toml 2ファイルシステム設計(中央レジストリ+個別仕様書)
- 全プラグインにnyash_box.tomlテンプレート追加
- プラグイン優先機能(NYASH_USE_PLUGIN_BUILTINS=1)文書化
- ビルトインBox削除準備(ChatGPT5実装中)
- ネイティブビルドデモ追加(Linux/Windows動作確認済み)
Everything is Box → Everything is Plugin への歴史的転換!
開発20日目にしてビルトインBox全削除という革命的決定。
🤖 Generated with Claude Code
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-30 01:33:52 +09:00
8e58942726
feat: プラグインパスをOS非依存に更新(.so拡張子削除)
...
- nyash.tomlからすべての.so拡張子を削除
- plugin_loader_v2のresolve_library_pathが自動的に適切な拡張子を追加
- Linux: .so
- Windows: .dll
- macOS: .dylib
- クロスプラットフォーム対応の準備完了
2025-08-29 23:11:21 +09:00
1eee62a8ea
feat(jit): JIT Strictモード実装とプラグイン経路の安定化
...
- InvokePolicy/Observe導入でLowererの分岐をスリム化
- ArrayBox/MapBox/StringBoxのプラグイン経路統一
- 特殊コメント機能(@jit-debug, @plugin-builtins, @jit-strict)実装
- 型ヒント伝搬パス(TypeHintPass)を独立モジュール化
- VM→Plugin引数整合の安定化(I64統一、IntegerBox自動プリミティブ化)
- StringBoxのpost-birth初期化(空文字列セグフォルト修正)
- JIT観測サンプル追加(Array/Map/String)
🤖 Generated with [Claude Code](https://claude.ai/code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-29 21:39:47 +09:00
3d8ba3f3ec
fix(jit): NewBoxのJIT安全化とDebugBox Phase 1実装
...
- NewBoxのJIT扱いを安全化(src/jit/lower/core.rs)
- NYASH_USE_PLUGIN_BUILTINS=1 && args.is_empty() かつ StringBox/IntegerBox のみJIT許可
- ArrayBox/MapBox等のプラグインBoxまたは引数ありはunsupportedとしてカウント
- unsupported>0の関数はJIT対象外となりVM実行にフォールバック(Segfault回避)
- DebugBox Phase 1実装(JITトレース機能)
- tracePluginCalls(bool)でJITシムトレースON/OFF
- getJitEvents()で直近のJITイベント取得
- src/jit/shim_trace.rs追加でトレース基盤実装
- Printのサポート
- PrintはJIT非対応に戻しVM経路で確実に出力(出力消失解消)
- テストとサンプル追加
- examples/jit_plugin_invoke_param_array.nyash: 最小JITスモークテスト
- examples/py_result_*.nyash: Python plugin結果チェーン処理デモ
- PyRuntimeBox拡張
- str()メソッドでPyObjectのstring表現を取得可能に
- エラーハンドリング改善とResultチェーンサポート
🤖 Generated with [Claude Code](https://claude.ai/code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-29 13:46:18 +09:00
d24149d0a1
feat: Phase 10.5 Python統合プラグインとAOTビルド対応
...
- Pythonプラグイン(PyRuntimeBox/PyObjectBox)を追加
- eval, import, getattr, call, callKw, strメソッド実装
- math.sqrtデモ等のサンプルコード追加
- AOTビルドサポート追加
- libnyrtランタイムライブラリ
- build_aot.shビルドスクリプト
- .gitignore改善
- JSONLとDOTファイル除外
- プラグインのビルド成果物除外
- 不要ファイル削除
- nekocode-temp, zenn_articles
- 一時的なログファイル類
Phase 10.1の新計画に基づいて、プラグインBox統一化を推進
2025-08-29 10:22:44 +09:00
12adde9477
🎉 Phase 10.10: Nyash→JIT→Native EXE achieved\! (20 days from inception\!)
...
Revolutionary milestone: Complete native executable generation pipeline
- Created minimal nyrt (Nyash Runtime) library for standalone executables
- Implemented plugin bridge functions (nyash_plugin_invoke3_i64 etc)
- Added birth handle exports (nyash.string.birth_h) for linking
- Changed export name from main→ny_main to allow custom entry point
- Successfully generated and executed native binary returning "ny_main() returned: 1"
Timeline of miracles:
- 2025-08-09: Nyash language created (first commit)
- 2025-08-13: JIT planning started (4 days later)
- 2025-08-29: Native EXE achieved (today - just 20 days total\!)
This proves the plugin Box C ABI unification strategy works perfectly for
both JIT execution and AOT native compilation. The same plugin system
that enables dynamic loading now powers static linking for zero-overhead
native executables\!
Next: Expand AOT support for more instructions and optimize nyrt size.
🚀 Generated with [Claude Code](https://claude.ai/code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-29 08:36:07 +09:00
c954b1f520
feat(plugins): ArrayBox/MapBoxプラグイン実装とPhase 10.1計画
...
🎯 革命的発見: プラグインC ABI = JIT→EXE変換の統一基盤
## 主な変更点
- ArrayBoxプラグイン: get/set/push/size/is_empty実装
- MapBoxプラグイン: size/get/has実装(ROメソッドのみ)
- Phase 10.1ドキュメント: プラグインBox統一化計画
- デモファイル3種: プラグイン動作確認用
## 技術的詳細
- BID-FFI (Box ID Foreign Function Interface) 活用
- 既存のプラグインシステムでJIT/AOT統一可能
- スタティックリンクでオーバーヘッド解消
- "Everything is Box → Everything is Plugin → Everything is Executable"
## テスト済み
- array_plugin_demo.nyash: 基本動作確認 ✅
- array_plugin_set_demo.nyash: set操作確認 ✅
- map_plugin_ro_demo.nyash: RO操作確認 ✅
🤖 Generated with [Claude Code](https://claude.ai/code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-29 04:37:30 +09:00
4167491e92
docs: JIT→EXE実現のための革新的アプローチを文書化
...
- プラグインBox統一化によるC ABI活用案
- すべてのBoxをプラグイン化する提案
- 既存のBID-FFIシステムを再利用
- Gemini/Codex先生の技術的助言も統合
関連: Phase 10.x, 自己ホスティング計画
2025-08-29 03:28:42 +09:00
25fbebd650
docs: AOT/ネイティブコンパイル情報をexecution-backends.mdに追加
...
- 4つ目の実行方式としてAOT(Ahead-of-Time)コンパイルを文書化
- MIR→WASM→.cwasm のコンパイルパイプラインを説明
- wasm-backend featureでのビルド方法を明記
- 現在の実装状況(完全なスタンドアロン実行ファイルはTODO)を記載
- CLAUDE.mdのWASM説明も3種類(Rust→WASM、Nyash→WASM、Nyash→AOT)に更新
- CURRENT_TASK.mdにPhase 10.9/10.10の完了項目を追加
ChatGPT5さんのAOT試行に対応した適切なドキュメント配置を実施
🤖 Generated with [Claude Code](https://claude.ai/code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-29 02:05:39 +09:00
d67f27f4b8
Phase 10.10: GC Switchable Runtime & Unified Debug System 実装完了
...
Phase 10.10の主要実装:
- GcConfigBox: GC設定の実行時制御(counting/trace/barrier_strict)
- DebugConfigBox: デバッグ設定の統一管理(JIT events/stats/dump/dot)
- メソッドディスパッチ: system_methods.rsで両Boxのメソッド実装
- CountingGC動作確認: write_barriers正常カウント(VM実行時)
技術的詳細:
- BoxCore/BoxBase統一アーキテクチャを活用
- setFlag/getFlag/apply/summaryメソッドで統一API提供
- 環境変数経由でVM/JITランタイムと連携
- GcConfigBox.apply()は次回実行から有効(ランタイム作成前に環境変数参照)
テスト済み:
- examples/gc_counting_demo.nyash: CountingGCの動作確認
- write_barriers=3でArray.push/set, Map.setを正しくカウント
- NYASH_GC_TRACE=1でGC統計出力確認
Box-First哲学の体現: 設定も制御も観測もすべてBox!
🤖 Generated with [Claude Code](https://claude.ai/code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-28 22:31:51 +09:00
4e1b595796
AI協調開発研究ドキュメントの完成と Phase 10.9-β 進捗
...
【AI協調開発研究】
- AI二重化モデルの学術論文draft完成(workshop_paper_draft.md)
- 「隠れた危機」分析とbirthの原則哲学化
- TyEnv「唯一の真実」協調会話を保存・研究資料に統合
- papers管理構造の整備(wip/under-review/published分離)
【Phase 10.9-β HostCall進捗】
- JitConfigBox: relax_numeric フラグ追加(i64→f64コアーション制御)
- HostcallRegistryBox: 署名検証・白黒リスト・コアーション対応
- JitHostcallRegistryBox: Nyash側レジストリ操作API
- Lower統合: env直読 → jit::config::current() 参照に統一
- 数値緩和設定: NYASH_JIT_HOSTCALL_RELAX_NUMERIC/Config.set_flag
【検証サンプル拡充】
- math.sin/cos/abs/min/max 関数スタイル(examples/jit_math_function_style_*.nyash)
- 境界ケース: 署名不一致・コアーション許可・mutating拒否サンプル
- E2E実証: String.length→allow, Array.push→fallback, math関数の署名一致観測
🤖 Generated with [Claude Code](https://claude.ai/code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-28 12:09:09 +09:00
e54561e69f
Phase 10.7 - JIT統計とイベント機能の完成
...
主要な実装:
- PHI(b1)統計追跡: phi_total_slots/phi_b1_slotsをJSON出力
- 関数単位統計API: JitStatsBox.perFunction()で詳細統計取得
- JITイベントシステム: compile/execute/fallback/trapをJSONL形式で記録
- Store/Load命令対応: ローカル変数を含む関数のJIT実行が可能に
新しいBox:
- JitStatsBox: JIT統計の取得
- JitConfigBox: JIT設定の管理(将来用)
- JitEventsBox: イベントのJSONL出力(将来用)
- JitPolicyBox: 実行ポリシー管理(将来用)
CLI拡張:
- --jit-exec, --jit-stats, --jit-dump等のフラグ追加
- --jit-directモードでの独立JIT実行
- NYASH_JIT_*環境変数によるきめ細かい制御
ドキュメント:
- Phase 10.7実装計画の詳細化
- Phase 10.9 (ビルトインBox JIT) の計画追加
- JIT統計JSONスキーマ v1の仕様化
ChatGPT5との共同開発により、JIT基盤が大幅に強化されました。
次はPhase 10.9でビルトインBoxのJIT対応を進め、
Python統合(Phase 10.1)への道を開きます。
🤖 Generated with [Claude Code](https://claude.ai/code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-28 09:26:58 +09:00
99e59e24e2
LowerCore: stabilize minimal PHI by tracking Phi dst and pushing block param when that ValueId is requested; verified jit_phi_demo returns merged value under cranelift.
2025-08-27 17:58:50 +09:00
633a073a30
Phase 10.7 (NYASH_JIT_PHI_MIN=1): Minimal PHI support for single-diamond via block params; extend IRBuilder with block-param/jump-args APIs; implement in CraneliftBuilder; update LowerCore two-pass for PHI wiring.
2025-08-27 17:52:37 +09:00
7dac50d139
Add examples/jit_branch_demo.nyash for Phase 10.7 validation.
2025-08-27 17:09:15 +09:00
ddae7fe1fc
Phase 10_6b scheduler complete; 10_4 GC hooks + counting/strict tracing; 10_c minimal JIT path (i64/bool consts, binop/compare/return, hostcall opt-in); docs & examples; add Phase 10.7 roadmap (JIT branch wiring + minimal ABI).
2025-08-27 17:06:46 +09:00
de03514085
feat: Phase 10_b JIT implementation progress + academic paper ideas
...
Phase 10_b JIT Lower implementation:
- IRBuilder abstraction with NoopBuilder (emit counting) ✅
- CraneliftBuilder skeleton (feature `cranelift-jit`) ✅
- LowerCore implementation (Const/Copy/BinOp/Cmp/Branch/Ret) ✅
- Engine.compile with builder selection and JIT handle generation ✅
- JIT function table with stub functions ✅
- Basic i64 const/binop/ret emission for Cranelift
- VM execution path with NYASH_JIT_EXEC=1 support
Academic ideas and analysis:
- "Everything is Thread-Safe Box" concept
- "GC as debug tool" paradigm analysis
- GC switchable semantic equivalence documentation
- Gemini & Codex evaluation on academic paper potential
- Nyash academic papers potential themes
Current limitations:
- Return values limited to i64 (VMValue::Integer)
- Arguments not yet supported
- Compare/Branch emit not implemented
- Trap→VM fallback not implemented
🤖 Generated with Claude Code
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-27 03:16:57 +09:00
6eda81f5db
feat: Major documentation reorganization and unified Box design updates
...
## Documentation & Organization
- Moved copilot_issues.txt → 00_MASTER_ROADMAP.md (phases folder)
- Created Phase 9.79b.1 & 9.79b.2 plans for unified Box implementation
- Updated unified-box-design-deep-analysis.md with ChatGPT5 insights
- Added P2P documentation and examples (ping-pong, self-ping)
## Code Updates
- P2PBox: Reverted to original error state for demonstration
- VM: Enhanced BoxCall dispatch for unified approach
- Updated box factory, interpreter calls, and transport layer
## Cleanup & Privacy
- Removed private/ and private_test/ from git tracking
- Added private folders to .gitignore for security
- Cleaned root directory: moved backups, removed temp files
- Moved consultation files to docs/archive/consultations/
## Other Improvements
- Added object literal syntax improvement idea
- Updated CLAUDE.md with master roadmap reference
- Updated CURRENT_TASK.md with latest progress
🤖 Generated with [Claude Code](https://claude.ai/code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-26 20:30:07 +09:00
8f82437c58
feat: Windows GUI development with egui - simple notepad example
...
- Fixed EguiBox Send+Sync trait bounds for thread safety
- Added missing Arc import for EguiBox implementation
- Simplified font setup in Windows notepad example
- Successfully built 4.5MB Windows GUI executable
- Nyash can now create native Windows desktop applications! 🎉
2025-08-20 08:03:36 +09:00
bab57e7c07
🎉 feat: ChatGPT5による奇跡の全テスト修復完了!
...
- instance_v2移行で破綻していた440個のテストを30分で全修正
- git巻き戻しレベルの状況から完全復活
- 人間には不可能な速度での大規模整合性修正
🤖 Generated with [Claude Code](https://claude.ai/code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-20 04:45:26 +09:00
621bf7cc3d
docs: reorganize into 説明書/予定/archive; update docs/README.md and CLAUDE.md; move root .nyash to local_tests; consolidate native-plan notes into README + archive
2025-08-13 18:54:02 +09:00
16cd53d125
Complete Canvas Box ecosystem with 10 professional WASM demos
...
Co-authored-by: moe-charm <217100418+moe-charm@users.noreply.github.com >
2025-08-13 00:36:32 +00:00
cfe550ac01
Implement core Canvas Boxes and 5 WASM demos
...
Co-authored-by: moe-charm <217100418+moe-charm@users.noreply.github.com >
2025-08-13 00:27:07 +00:00
ccb3204a35
🚀 feat: ":"継承演算子実装+全14Box型の包括的ドキュメント化完成
...
## 🔧 言語機能改善
- from予約語問題を解決する":"継承演算子を実装
- box Child : Parent 構文でより直感的な継承表現
- tokenizer/parserを更新、from を変数名として使用可能に
## 📚 ドキュメント大改善(1000行以上追加)
全14Box型に包括的なJavaDoc風ドキュメントを追加:
- StringBox: 文字列操作メソッド群
- IntegerBox/BoolBox: 基本データ型と演算子
- MathBox/RandomBox/TimeBox: 計算・ユーティリティ
- ConsoleBox/DebugBox/SoundBox: システムIO
- MapBox/NullBox: データ構造
- EguiBox: デスクトップGUI
- SimpleIntentBox: P2P通信
各Boxに概要・メソッド一覧・使用例・実用例・注意事項を完備
## 🧹 プロジェクト整理
- ルートディレクトリから60個のテストファイルを削除
(development/root_tests/に移動済み)
- 不要ファイル削除: bmp, tar.xz, html, 空フォルダ等
- examplesフォルダへ適切なファイルを移動
## 📝 その他の更新
- CLAUDE.md: パーサーデバッグ機能の説明追加
- sessions/: AI相談記録2件を保存
- from予約語問題の解決策検討
- 標準Box型(ArrayBox等)の設計相談
2025-08-10 11:32:32 +09:00
e7f6666917
🎨 feat: EguiBox GUI開発基盤完成 + パーサー無限ループバグ修正
...
## 🚀 主要機能追加
### EguiBox - GUI開発基盤
- Windows版GUIメモ帳アプリ (simple_notepad.rs, nyash_notepad_jp.rs)
- 日本語フォント対応 (NotoSansJP-VariableFont_wght.ttf)
- BMPアイコン表示システム (c_drive_icon.bmp)
- Windowsエクスプローラー風アプリ (nyash_explorer.rs)
- アイコン抽出システム (test_icon_extraction.rs)
### ビジュアルプログラミング準備
- NyashFlow プロジェクト設計完成 (NYASHFLOW_PROJECT_HANDOVER.md)
- ビジュアルノードプロトタイプ基盤
- WebAssembly対応準備
## 🔧 重大バグ修正
### パーサー無限ループ問題 (3引数メソッド呼び出し)
- 原因: メソッドパラメータ解析ループの予約語処理不備
- 修正: src/parser/mod.rs - 非IDENTIFIERトークンのエラーハンドリング追加
- 効果: "from"等の予約語で適切なエラー報告、ハング→瞬時エラー
### MapBoxハング問題調査
- MapBox+3引数メソッド呼び出し組み合わせ問題特定
- バグレポート作成 (MAPBOX_HANG_BUG_REPORT.md)
- 事前評価vs必要時評価の設計問題明確化
## 🧹 コード品質向上
- box_methods.rs を8モジュールに機能分離
- 一時デバッグコード全削除 (eprintln\!, unsafe等)
- 構文チェック通過確認済み
## 📝 ドキュメント整備
- CLAUDE.md にGUI開発セクション追加
- Gemini/ChatGPT先生相談ログ保存 (sessions/)
- 段階的デバッグ手法確立
## 🎯 次の目標
- must_advance\!マクロ実装 (無限ループ早期検出)
- コマンド引数でデバッグ制御 (--debug-fuel)
- MapBox問題の根本修正
🤖 Generated with [Claude Code](https://claude.ai/code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-08-10 07:54:03 +09:00
0bed0c0271
🎉 initial commit: Nyash Programming Language完成版
...
🚀 主要機能:
• Everything is Box哲学による革新的アーキテクチャ
• WebAssemblyブラウザー対応プレイグラウンド
• アーティスト協同制作デモ - 複数Boxインスタンス実証
• 視覚的デバッグシステム - DebugBox完全統合
• static box Mainパターン - メモリ安全設計
⚡ 言語機能:
• NOT/AND/OR/除算演算子完全実装
• ジェネリクス/テンプレートシステム
• 非同期処理(nowait/await)
• try/catchエラーハンドリング
• Canvas統合グラフィックス
🎨 ブラウザー体験:
• 9種類のインタラクティブデモ
• リアルタイムコード実行
• WebCanvas/WebConsole/WebDisplay
• モバイル対応完了
🤖 Built with Claude Code collaboration
Ready for public release!
2025-08-09 15:14:44 +09:00