From 70c64c69bc48fcd0c64723cba42a7d9a4ac94745 Mon Sep 17 00:00:00 2001 From: Edoardo Paone Date: Mon, 2 Dec 2024 10:37:19 +0100 Subject: [PATCH] fix previous commit --- .../runners/dace_fieldview/gtir_python_codegen.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/gt4py/next/program_processors/runners/dace_fieldview/gtir_python_codegen.py b/src/gt4py/next/program_processors/runners/dace_fieldview/gtir_python_codegen.py index 95b7ce5213..4bdb602f5f 100644 --- a/src/gt4py/next/program_processors/runners/dace_fieldview/gtir_python_codegen.py +++ b/src/gt4py/next/program_processors/runners/dace_fieldview/gtir_python_codegen.py @@ -123,8 +123,10 @@ class PythonCodegen(codegen.TemplatedGenerator): def visit_FunCall(self, node: gtir.FunCall, args_map: dict[str, gtir.Node]) -> str: if isinstance(node.fun, gtir.Lambda): # update the mapping from lambda parameters to corresponding argument expressions - args_map |= {p.id: arg for p, arg in zip(node.fun.params, node.args, strict=True)} - return self.visit(node.fun.expr, args_map=args_map) + lambda_args_map = args_map | { + p.id: arg for p, arg in zip(node.fun.params, node.args, strict=True) + } + return self.visit(node.fun.expr, args_map=lambda_args_map) elif cpm.is_call_to(node, "deref"): assert len(node.args) == 1 if not isinstance(node.args[0], gtir.SymRef):