Fixes #2181 -- conditional assignment as subexpression

* Parenthesize compilation of `||=` and `&&=` (when needed).
* Fix variable caching for `?=`
Merge pull request #3211 from marchaefner/issue2181

Fix compilation for conditional assignment