From 653db0015003743abba09be1b081efdce435d430 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20P=C3=A9ters?= Date: Tue, 16 Apr 2019 10:49:36 +0200 Subject: [PATCH] lazy: add support for __radd__ ("foo" + form_var_bla) (#29951) --- wcs/variables.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/wcs/variables.py b/wcs/variables.py index 453d8a02e..078064164 100644 --- a/wcs/variables.py +++ b/wcs/variables.py @@ -421,6 +421,9 @@ class LazyFieldVar(object): def __add__(self, other): return self.get_value().__add__(other) + def __radd__(self, other): + return other + self.get_value() + def __mul__(self, other): return self.get_value().__mul__(other)