From 038884232b6efbabb414cb011fa0fc4e3b4c8fd6 Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Sat, 13 Jun 2026 09:26:56 -0700 Subject: I did some silly things. This one doesn't build. --- src/lib.rs | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'src/lib.rs') diff --git a/src/lib.rs b/src/lib.rs index b413d2a..1ecd3b8 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -46,7 +46,7 @@ impl View { for output in &self.outputs { let mut buf = String::new(); let sc = StatefulContext::root( input ); - exec( &sc, &output.code, &mut buf )?; + exec::( &sc, &output.code, &mut buf )?; out_vars.insert( output.name.clone(), Value::String(buf) ); } Ok(out_vars) @@ -201,7 +201,14 @@ fn exec(input: &StatefulContext, tokens: &Vec, buf let Value::List(list) = value { for rec in &list { if let Value::Dictionary(d) = rec { - exec( &input.local(d), code, buf )? + if matches!(d, Context) && + matches!(input.root, Context) { + println!("Matches."); + } else { + println!("Doesn't match."); + + } + exec( &StatefulContext::full(input.root,d), code, buf )? } } } -- cgit v1.2.3