## Re: [PyX-devel] Re: [PyX-checkins] pyx/test/experimental solve.py,1.2,1.3

 Re: [PyX-devel] Re: [PyX-checkins] pyx/test/experimental solve.py,1.2,1.3 From: Magnus Lie Hetland - 2004-07-28 19:38:48 ```Joerg Lehmann : > [snip] > IMHO it's too implicit. In particular, not having to explicitly specify > the solver is probably not a good idea.=20 I think using =3D=3D for anything with side-effects (or even anything tha= t isn't interpretable as a boolean equality check) is quite unfortunate. It might *look* good, but still... (if x =3D=3D y: alwaysexecuted()...) Using a method or function may be a bit more verbose but still much better, IMO. We don't really have much to complain about; the Java people have to use foo.equals(bar) where we can use foo =3D=3D bar :) I think solver.equate(x, y) or something similar (e.g. "equals", "equal", "eq") would be better. If one was feeling adventurous, one could even do stuff like solver(x =3D y) but only for single-variable left-hand-sides, of course. It would be possible to do some property magic too... I'm pretty sure I could write code such that a.x =3D b.y a.y =3D b.x could be turned into a set of equations (by using wrapper classes around the objects returned by the properties, somewhat like bound methods). Just musing. > J=F6rg --=20 Magnus Lie Hetland "Canned Bread: The greatest thing since sliced http://hetland.org bread!" [from a can in Spongebob Squarepants] ```