Yes, and it was considered bad form there too. In both cases, it
leads one to wonder, did the author *mean* to assign, or just forget
the extra = in ==? If the code structure is such that you pretty much
HAVE to do that, then put a comment to that effect. I've also seen
many people slap parens around the assignment, i.e., "if (obj =
get_client)", in *both* languages -- that will shut up the warnings
some C compilers would otherwise (rightfully) generate.
--
Dave Aronson, consulting software developer of Codosaur.us,
PullRequestRoulette.com,
Blog.Codosaur.us, and Dare2XL.com.