Refactor VM field access to use Rc clones

The VM's field access logic has been refactored to clone `Rc` pointers
for addresses and field identifiers. This change aims to improve
efficiency by avoiding unnecessary dereferencing and copying of values
when accessing fields within records and objects.

Additionally, the `Value::Object` handling in `BoundKind::GetField` has
been refined to more explicitly manage `RecordSeries` and `StreamNode`
types, ensuring that field access is handled polymorphically and
efficiently without copying underlying data structures.
This commit is contained in:
Michael Schimmel
2026-03-13 18:44:43 +01:00
parent b87a6d7ada
commit d035da9d91
2 changed files with 7 additions and 29 deletions
+1 -1
View File
@@ -15,7 +15,7 @@ use crate::ast::compiler::bound_nodes::{
};
use crate::ast::compiler::dumper::Dumper;
use crate::ast::compiler::lambda_collector::LambdaCollector;
use crate::ast::compiler::lowering::{ExecNode, Lowering};
use crate::ast::compiler::lowering::{Lowering, ExecNode};
use crate::ast::compiler::macros::{MacroEvaluator, MacroExpander, MacroRegistry};
use crate::ast::compiler::optimizer::Optimizer;
use crate::ast::compiler::specializer::{FunctionRegistry, MonoCache, Specializer};