From ae84214f453feb68dd949220e4cd723031211987 Mon Sep 17 00:00:00 2001 From: Jonathan Guyer Date: Tue, 1 Oct 2024 14:41:31 -0400 Subject: [PATCH] Reverse order of pop'd arguments Successive pops reverses, so reverse back --- fipy/variables/operatorVariable.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fipy/variables/operatorVariable.py b/fipy/variables/operatorVariable.py index 80d5c01602..e34af599ab 100644 --- a/fipy/variables/operatorVariable.py +++ b/fipy/variables/operatorVariable.py @@ -250,8 +250,8 @@ def _py3kInstructions(self, op, style, argDict, id, freshen): pass elif ins.opname == 'CALL': # New in Python 3.11 - kwargs = [kw + "=" + str(stack.pop()) for kw in kws] - positionals = [stack.pop() for _ in range(ins.argval - len(kws))] + kwargs = [kw + "=" + str(stack.pop()) for kw in kws][::-1] + positionals = [stack.pop() for _ in range(ins.argval - len(kws))][::-1] callable = stack.pop() if len(stack) > 0: call_self = callable