Fix __self__ with params, and define_boolexpr() as obj method.

When __self__ is called with params, it only returns itself if the
boolean expression for those params returns true.

This fixes a bug with via/to accessors that prevents replacing
poor names with aliases from happening easily.