revert: 古いプラグインシステム実装前の状態に巻き戻し

- ソースコードをcommit 3f7d71fの状態に復元(古いプラグインシステム実装前)
- docsフォルダは最新の状態を維持(BID-FFI設計ドキュメント含む)
- nyashバイナリの基本動作確認済み
- BID-FFIシステムをクリーンに再実装する準備完了

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

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Moe Charm
2025-08-18 08:34:19 +09:00
parent 75868a5a96
commit bec0e9bc92
35 changed files with 731 additions and 2757 deletions

View File

@ -350,13 +350,13 @@ impl NyashInterpreter {
// 2. local変数をチェック
if let Some(local_value) = self.local_vars.get(name) {
eprintln!("🔍 DEBUG: Found '{}' in local_vars, type: {}", name, local_value.type_name());
eprintln!("🔍 DEBUG: Found '{}' in local_vars", name);
// 🔧 修正clone_box() → Arc::clone() で参照共有
let shared_value = Arc::clone(local_value);
eprintln!("✅ RESOLVE_VARIABLE shared reference: {} id={}, type: {}",
name, shared_value.box_id(), shared_value.type_name());
eprintln!("✅ RESOLVE_VARIABLE shared reference: {} id={}",
name, shared_value.box_id());
return Ok(shared_value);
}
@ -478,12 +478,7 @@ impl NyashInterpreter {
/// local変数を宣言関数内でのみ有効
pub(super) fn declare_local_variable(&mut self, name: &str, value: Box<dyn NyashBox>) {
eprintln!("🔍 DEBUG: declare_local_variable '{}' with type: {}, id: {}",
name, value.type_name(), value.box_id());
let arc_value: Arc<dyn NyashBox> = Arc::from(value);
eprintln!("🔍 DEBUG: After Arc::from, type: {}, id: {}",
arc_value.type_name(), arc_value.box_id());
self.local_vars.insert(name.to_string(), arc_value);
self.local_vars.insert(name.to_string(), Arc::from(value));
}
/// outbox変数を宣言static関数内で所有権移転