- Fixed deadlock in FileBox plugin copyFrom implementation (single lock) - Added TLV Handle (tag=8) parsing in calls.rs for returned BoxRefs - Improved plugin loader with config path consistency and detailed logging - Fixed loader routing for proper Handle type_id/fini_method_id resolution - Added detailed logging for TLV encoding/decoding in plugin_loader_v2 Test docs/examples/plugin_boxref_return.nyash now works correctly: - cloneSelf() returns FileBox Handle properly - copyFrom(Box) accepts plugin Box arguments - Both FileBox instances close and fini correctly 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
🌐 Nyash WASM ガイド
Nyash WebAssembly(WASM)実行に関する包括的ガイド
📖 ドキュメント一覧
基本ガイド
技術仕様
- FFI/BIDチュートリアル - 外部API統合方法
- メモリ管理 - WASM メモリレイアウト・最適化
🚀 クイックスタート
WASM コンパイル
# 基本コンパイル
./target/release/nyash --compile-wasm program.nyash
# AOT コンパイル(配布用)
./target/release/nyash --aot program.nyash
ブラウザー実行
<!DOCTYPE html>
<html>
<body>
<script>
WebAssembly.instantiateStreaming(fetch('program.wasm'), importObject)
.then(instance => instance.exports.main());
</script>
</body>
</html>
🎯 実行方式選択
| 用途 | 方式 | コマンド |
|---|---|---|
| 開発・テスト | インタープリター | nyash program.nyash |
| 高速実行 | VM | nyash --backend vm program.nyash |
| Web配布 | WASM | nyash --compile-wasm program.nyash |
| ネイティブ配布 | AOT | nyash --aot program.nyash |
📊 性能比較
| バックエンド | 実行速度 | 配布サイズ | 依存関係 |
|---|---|---|---|
| インタープリター | 1x | - | Rust |
| VM | 20.4x | - | Rust |
| WASM | 13.5x | 小 | なし |
| AOT | 目標1000x+ | 小 | なし |
🔗 関連ドキュメント
最終更新: 2025-08-15