Make -imp simplify more, and use it in more places.

Also add filter tests for implication.
Fix tc-let for mutable variables.

Closes PR 14415.